文件操作 - milliseconds.d.cts
返回文件管理
返回主菜单
删除本文件
文件: /var/www/OLD/node_modules/date-fns/milliseconds.d.cts
编辑文件内容
import type { Duration } from "./types.js"; /** * @name milliseconds * @category Millisecond Helpers * @summary * Returns the number of milliseconds in the specified, years, months, weeks, days, hours, minutes and seconds. * * @description * Returns the number of milliseconds in the specified, years, months, weeks, days, hours, minutes and seconds. * * One years equals 365.2425 days according to the formula: * * > Leap year occurs every 4 years, except for years that are divisible by 100 and not divisible by 400. * > 1 mean year = (365+1/4-1/100+1/400) days = 365.2425 days * * One month is a year divided by 12. * * @param duration - The object with years, months, weeks, days, hours, minutes and seconds to be added. * * @returns The milliseconds * * @example * // 1 year in milliseconds * milliseconds({ years: 1 }) * //=> 31556952000 * * // 3 months in milliseconds * milliseconds({ months: 3 }) * //=> 7889238000 */ export declare function milliseconds({ years, months, weeks, days, hours, minutes, seconds, }: Duration): number;
修改文件时间
将文件时间修改为当前时间的前一年
删除文件