tdesign-vue-next-starter/src/utils/date.ts
PY 86f73de893 fix/githubaction/config (#14)
* fix: githubactions config

* fix: update build env

* fix: remove cache

Co-authored-by: ivringpeng <pengyue970725@gmail.com>
2021-12-06 22:53:37 +08:00

13 lines
321 B
TypeScript

// 获取常用时间
import dayjs from 'dayjs';
export const LAST_7_DAYS = [
dayjs().subtract(7, 'day').format('YYYY-MM-DD'),
dayjs().subtract(1, 'day').format('YYYY-MM-DD'),
];
export const LAST_30_DAYS = [
dayjs().subtract(30, 'day').format('YYYY-MM-DD'),
dayjs().subtract(1, 'day').format('YYYY-MM-DD'),
];