Skip to content

formatTimeAgoIntl ​

描述 ​

使用 Intl.RelativeTimeFormat 格式化时间。

示例 ​

ts
import { formatTimeAgoIntl } from '@base-web-kits/base-tools-vue';

const str = formatTimeAgoIntl(new Date(Date.now() - 1000));
``` 示例代码

来源 ​

VueUse