mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-04-21 13:27:15 +08:00
Merge pull request #5510 from chrootsu/lodash-isArguments
lodash: changed _.isArguments() method
This commit is contained in:
@@ -1195,6 +1195,12 @@ result = <boolean>_(1).gte(2);
|
||||
result = <boolean>_([]).gte(2);
|
||||
result = <boolean>_({}).gte(2);
|
||||
|
||||
// _.isArguments
|
||||
result = <boolean>_.isArguments(any);
|
||||
result = <boolean>_(1).isArguments();
|
||||
result = <boolean>_<any>([]).isArguments();
|
||||
result = <boolean>_({}).isArguments();
|
||||
|
||||
// _.isArray
|
||||
result = <boolean>_.isArray(any);
|
||||
result = <boolean>_(1).isArray();
|
||||
@@ -1455,8 +1461,6 @@ interface FirstSecond {
|
||||
}
|
||||
result = <FirstSecond>_.invert({ 'first': 'moe', 'second': 'larry' });
|
||||
|
||||
(function (...args: any[]) { return <boolean>_.isArguments(arguments); })(1, 2, 3);
|
||||
|
||||
result = <boolean>_.isBoolean(null);
|
||||
|
||||
result = <boolean>_.isElement(document.body);
|
||||
|
||||
27
lodash/lodash.d.ts
vendored
27
lodash/lodash.d.ts
vendored
@@ -6162,6 +6162,23 @@ declare module _ {
|
||||
gte(other: any): boolean;
|
||||
}
|
||||
|
||||
//_.isArguments
|
||||
interface LoDashStatic {
|
||||
/**
|
||||
* Checks if value is classified as an arguments object.
|
||||
* @param value The value to check.
|
||||
* @return Returns true if value is correctly classified, else false.
|
||||
*/
|
||||
isArguments(value?: any): boolean;
|
||||
}
|
||||
|
||||
interface LoDashWrapperBase<T, TWrapper> {
|
||||
/**
|
||||
* @see _.isArguments
|
||||
*/
|
||||
isArguments(): boolean;
|
||||
}
|
||||
|
||||
//_.isArray
|
||||
interface LoDashStatic {
|
||||
/**
|
||||
@@ -7011,16 +7028,6 @@ declare module _ {
|
||||
invert(object: any): any;
|
||||
}
|
||||
|
||||
//_.isArguments
|
||||
interface LoDashStatic {
|
||||
/**
|
||||
* Checks if value is an arguments object.
|
||||
* @param value The value to check.
|
||||
* @return True if the value is an arguments object, else false.
|
||||
**/
|
||||
isArguments(value?: any): boolean;
|
||||
}
|
||||
|
||||
//_.isBoolean
|
||||
interface LoDashStatic {
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user