mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-10-04 06:47:03 +00:00
Add types definition for jstz (jsTimezoneDetect) (#11716)
* Add types definition for jstz (jsTimezoneDetect https://bitbucket.org/pellepim/jstimezonedetect) * Rename to jstimezonedetect
This commit is contained in:
committed by
Mohamed Hegazy
parent
bf103e8654
commit
12649b923f
@@ -0,0 +1,5 @@
|
||||
/// <reference path="jstimezonedetect.d.ts" />
|
||||
|
||||
import * as jstz from 'jstimezonedetect';
|
||||
|
||||
jstz.determine().name() === 'America/Montreal';
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
// Type definitions for jsTimezoneDetect
|
||||
// Project: https://bitbucket.org/pellepim/jstimezonedetect
|
||||
// Definitions by: Olivier Lamothe <https://github.com/olamothe/>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
interface JsTimezoneDetect {
|
||||
determine: ()=> {
|
||||
name: ()=> string;
|
||||
}
|
||||
}
|
||||
|
||||
declare var jstimezonedetect: JsTimezoneDetect;
|
||||
|
||||
declare module "jstimezonedetect" {
|
||||
export = jstimezonedetect;
|
||||
}
|
||||
Reference in New Issue
Block a user