-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.d.ts
56 lines (49 loc) · 1.25 KB
/
index.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
interface PromisifiedTimeout {
(ms: number): Promise<void>
}
declare namespace Utilities {
export class StopWatch {
#private
private digits
constructor(digits?: number)
/**
* Returns this StopWatch's raw duration in milliseconds
*/
get duration(): number
/**
* Returns a boolean indicating whether or not this StopWatch is running
*/
get isRunning(): boolean
/**
* Stops this StopWatch and returns with the human readable duration.
*/
stop(): string
/**
* Restarts this StopWatch
*/
restart(): this
/**
* Starts this StopWatch
*/
start(): this
/**
* Returns with the human readable duration.
*/
private symbol
}
/**
* Checks to see if an Object is empty or not
* @params obj Value to check
*/
export function isEmptyObject(obj: Record<string, unknown>): boolean
/**
* Checks if `obj` is an Object
* @params obj Value to check
*/
export function isObject(obj: any): boolean
export function mergeObjects<A extends object, B extends object>(objTarget: A, objSource: Readonly<B>): A & B
export const sleep: PromisifiedTimeout
export const isArray: (val: any) => boolean
}
export = Utilities
export as namespace Utilities