mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-10-04 23:07:06 +00:00
Merge pull request #22128 from alanblins/momenttimezoneguess
Update types for moment-timezone
This commit is contained in:
Vendored
+2
-2
@@ -1,6 +1,6 @@
|
||||
// Type definitions for moment-timezone.js 0.5
|
||||
// Project: http://momentjs.com/timezone/
|
||||
// Definitions by: Michel Salib <https://github.com/michelsalib>
|
||||
// Definitions by: Michel Salib <https://github.com/michelsalib>, Alan Brazil Lins <https://github.com/alanblins>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
import * as moment from 'moment';
|
||||
@@ -51,7 +51,7 @@ declare module "moment" {
|
||||
}): void;
|
||||
|
||||
names(): string[];
|
||||
guess(): string;
|
||||
guess(ignoreCache?: boolean): string;
|
||||
|
||||
setDefault(timezone: string): void;
|
||||
}
|
||||
|
||||
@@ -78,6 +78,8 @@ moment.tz.setDefault('America/Los_Angeles');
|
||||
|
||||
moment.tz.guess();
|
||||
|
||||
moment.tz.guess(true);
|
||||
|
||||
const zoneAbbr: string = moment.tz('America/Los_Angeles').zoneAbbr();
|
||||
|
||||
const zoneName: string = moment.tz('America/Los_Angeles').zoneName();
|
||||
|
||||
Reference in New Issue
Block a user