Merge pull request #4962 from chrootsu/lodash-keysIn

lodash: added _.keyIn() method
This commit is contained in:
Masahiro Wakame
2015-07-18 19:56:29 +09:00
2 changed files with 20 additions and 0 deletions
+3
View File
@@ -1018,6 +1018,9 @@ result = <boolean>_.isUndefined(void 0);
result = <string[]>_.keys({ 'one': 1, 'two': 2, 'three': 3 });
result = <string[]>_({ 'one': 1, 'two': 2, 'three': 3 }).keys().value();
result = <string[]>_.keysIn({ 'one': 1, 'two': 2, 'three': 3 });
result = <string[]>_({ 'one': 1, 'two': 2, 'three': 3 }).keysIn().value();
var mergeNames = {
'stooges': [
{ 'name': 'moe' },
+17
View File
@@ -6003,6 +6003,23 @@ declare module _ {
keys(): LoDashArrayWrapper<string>
}
//_.keysIn
interface LoDashStatic {
/**
* Creates an array of the own and inherited enumerable property names of object.
* @param object The object to query.
* @return An array of property names.
**/
keysIn(object?: any): string[];
}
interface LoDashObjectWrapper<T> {
/**
* @see _.keysIn
**/
keysIn(): LoDashArrayWrapper<string>
}
//_.mapValues
interface LoDashStatic {
/**