@types/lodash 4.14.180 → 4.14.181
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- lodash/README.md +1 -1
- lodash/common/function.d.ts +16 -0
- lodash/package.json +2 -2
lodash/README.md
CHANGED
|
@@ -8,7 +8,7 @@ This package contains type definitions for Lo-Dash (https://lodash.com).
|
|
|
8
8
|
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/lodash.
|
|
9
9
|
|
|
10
10
|
### Additional Details
|
|
11
|
-
* Last updated:
|
|
11
|
+
* Last updated: Tue, 29 Mar 2022 13:31:45 GMT
|
|
12
12
|
* Dependencies: none
|
|
13
13
|
* Global values: `_`
|
|
14
14
|
|
lodash/common/function.d.ts
CHANGED
|
@@ -368,6 +368,9 @@ declare module "../index" {
|
|
|
368
368
|
*/
|
|
369
369
|
trailing?: boolean | undefined;
|
|
370
370
|
}
|
|
371
|
+
interface DebounceSettingsLeading extends DebounceSettings {
|
|
372
|
+
leading: true;
|
|
373
|
+
}
|
|
371
374
|
interface DebouncedFunc<T extends (...args: any[]) => any> {
|
|
372
375
|
/**
|
|
373
376
|
* Call the original function, but applying the debounce rules.
|
|
@@ -394,6 +397,10 @@ declare module "../index" {
|
|
|
394
397
|
*/
|
|
395
398
|
flush(): ReturnType<T> | undefined;
|
|
396
399
|
}
|
|
400
|
+
interface DebouncedFuncLeading<T extends (...args: any[]) => any> extends DebouncedFunc<T> {
|
|
401
|
+
(...args: Parameters<T>): ReturnType<T>;
|
|
402
|
+
flush(): ReturnType<T>;
|
|
403
|
+
}
|
|
397
404
|
interface LoDashStatic {
|
|
398
405
|
/**
|
|
399
406
|
* Creates a debounced function that delays invoking func until after wait milliseconds have elapsed since
|
|
@@ -415,12 +422,17 @@ declare module "../index" {
|
|
|
415
422
|
* @param options.trailing Specify invoking on the trailing edge of the timeout.
|
|
416
423
|
* @return Returns the new debounced function.
|
|
417
424
|
*/
|
|
425
|
+
debounce<T extends (...args: any) => any>(func: T, wait: number | undefined, options: DebounceSettingsLeading): DebouncedFuncLeading<T>;
|
|
418
426
|
debounce<T extends (...args: any) => any>(func: T, wait?: number, options?: DebounceSettings): DebouncedFunc<T>;
|
|
419
427
|
}
|
|
420
428
|
interface Function<T extends (...args: any) => any> {
|
|
421
429
|
/**
|
|
422
430
|
* @see _.debounce
|
|
423
431
|
*/
|
|
432
|
+
debounce(
|
|
433
|
+
wait: number | undefined,
|
|
434
|
+
options: DebounceSettingsLeading
|
|
435
|
+
): T extends (...args: any[]) => any ? Function<DebouncedFuncLeading<T>> : never;
|
|
424
436
|
debounce(
|
|
425
437
|
wait?: number,
|
|
426
438
|
options?: DebounceSettings
|
|
@@ -430,6 +442,10 @@ declare module "../index" {
|
|
|
430
442
|
/**
|
|
431
443
|
* @see _.debounce
|
|
432
444
|
*/
|
|
445
|
+
debounce(
|
|
446
|
+
wait: number | undefined,
|
|
447
|
+
options: DebounceSettingsLeading
|
|
448
|
+
): T extends (...args: any[]) => any ? FunctionChain<DebouncedFuncLeading<T>> : never;
|
|
433
449
|
debounce(
|
|
434
450
|
wait?: number,
|
|
435
451
|
options?: DebounceSettings
|
lodash/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@types/lodash",
|
|
3
|
-
"version": "4.14.
|
|
3
|
+
"version": "4.14.181",
|
|
4
4
|
"description": "TypeScript definitions for Lo-Dash",
|
|
5
5
|
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/lodash",
|
|
6
6
|
"license": "MIT",
|
|
@@ -60,6 +60,6 @@
|
|
|
60
60
|
},
|
|
61
61
|
"scripts": {},
|
|
62
62
|
"dependencies": {},
|
|
63
|
-
"typesPublisherContentHash": "
|
|
63
|
+
"typesPublisherContentHash": "012e997ab7eafe91f13d511d95e41a2e7cb1d79a3f628e2f40d082d5db086c3b",
|
|
64
64
|
"typeScriptVersion": "3.9"
|
|
65
65
|
}
|