MCPcopy
hub / github.com/iamkun/dayjs / Duration

Interface Duration

types/plugin/duration.d.ts:28–74  ·  types/plugin/duration.d.ts::Duration

Source from the content-addressed store, hash-verified

26 type AddDurationType = CreateDurationType & ((duration: Duration) => Duration)
27
28 interface Duration {
29 new (input: string | number | object, unit?: string, locale?: string): Duration
30
31 clone(): Duration
32
33 humanize(withSuffix?: boolean): string
34
35 milliseconds(): number
36 asMilliseconds(): number
37
38 seconds(): number
39 asSeconds(): number
40
41 minutes(): number
42 asMinutes(): number
43
44 hours(): number
45 asHours(): number
46
47 days(): number
48 asDays(): number
49
50 weeks(): number
51 asWeeks(): number
52
53 months(): number
54 asMonths(): number
55
56 years(): number
57 asYears(): number
58
59 as(unit: DurationUnitType): number
60
61 get(unit: DurationUnitType): number
62
63 add: AddDurationType
64
65 subtract: AddDurationType
66
67 toJSON(): string
68
69 toISOString(): string
70
71 format(formatStr?: string): string
72
73 locale(locale: string): Duration
74 }
75}
76
77declare module class="st">'dayjs' {

Callers 72

parse.test.jsFile · 0.65
locale.test.jsFile · 0.65
browser.spec.jsFile · 0.65
query.test.jsFile · 0.65
timezone.test.jsFile · 0.65
badMutable.test.jsFile · 0.65
duration.test.jsFile · 0.65
duration.test.jsFile · 0.65
duration.test.jsFile · 0.65

Implementers 1

Durationsrc/plugin/duration/index.js

Calls

no outgoing calls

Tested by

no test coverage detected