UNPKG

926 BMarkdownView Raw
1# Installation
2> `npm install --save @types/ms`
3
4# Summary
5This package contains type definitions for ms (https://github.com/zeit/ms).
6
7# Details
8Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/ms.
9## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/ms/index.d.ts)
10````ts
11/**
12 * Short/Long format for `value`.
13 *
14 * @param {Number} value
15 * @param {{long: boolean}} options
16 * @return {String}
17 */
18declare function ms(value: number, options?: { long: boolean }): string;
19
20/**
21 * Parse the given `value` and return milliseconds.
22 *
23 * @param {String} value
24 * @return {Number}
25 */
26declare function ms(value: string): number;
27
28export = ms;
29
30````
31
32### Additional Details
33 * Last updated: Tue, 07 Nov 2023 09:09:39 GMT
34 * Dependencies: none
35
36# Credits
37These definitions were written by [Zhiyuan Wang](https://github.com/danny8002).
38
\No newline at end of file