import { default as dayjs } from 'dayjs'; declare const dateHelper: { /** * 时间格式化 * @param date 时间 * @param format 格式,如:YYYY-MM-DD * @returns */ formatDate: (date: number | string | Date | dayjs.Dayjs, format?: string, sourceFomat?: dayjs.OptionType) => string; /** * 字符串时间转时间戳 * https://dayjs.gitee.io/docs/zh-CN/parse/string-format * @param date 时间 * @param sourceFomat 为了保证结果一致,当解析除了 ISO 8601 格式以外的字符串时,您应该使用 String + Format * @returns */ toUnix: (date: number | string | Date | dayjs.Dayjs, sourceFomat?: dayjs.OptionType) => number; /** * 转Date格式 * https://dayjs.gitee.io/docs/zh-CN/parse/string-format * @param date * @param sourceFomat 为了保证结果一致,当解析除了 ISO 8601 格式以外的字符串时,您应该使用 String + Format */ toDate: (date: number | string | Date | dayjs.Dayjs, sourceFomat?: dayjs.OptionType) => Date; /** * 转dayjs格式 * @param date * @param sourceFomat */ toDayjs: (date: number | string | Date | dayjs.Dayjs, sourceFomat?: dayjs.OptionType) => dayjs.Dayjs; /** * 获取今天周几 * @param date * @param sourceFomat * @returns */ getWeek(date: number | string | Date | dayjs.Dayjs, sourceFomat?: dayjs.OptionType): number; }; export { dateHelper };