UNPKG

707 BTypeScriptView Raw
1import {inspect} from 'util';
2
3// @achrinza: One of the limitations of these definitions is that the class instance
4// isn't callable; Hence, changing the `value` class member must be done
5// directly. This is a TypeScript limitation as class constructors cannot
6// have a custom return value.
7export function DateString(value: DateString | string): DateString;
8export class DateString {
9 private _when: string;
10 private _date: Date;
11
12 get when(): string;
13 set when(val: string);
14
15 constructor(value: string);
16
17 toString(): DateString['when'];
18 toJSON(): {when: DateString['when']};
19 inspect(): string;
20 [inspect.custom]: DateString['inspect'];
21}