mirror of
https://github.com/wassname/DefinitelyTyped.git
synced 2026-08-25 11:11:46 +08:00
Added chainable definitions for _(...).pluck
This commit is contained in:
@@ -419,6 +419,7 @@ result = <IStoogesAge>_.min(stoogesAges, function (stooge) { return stooge.age;
|
||||
result = <IStoogesAge>_.min(stoogesAges, 'age');
|
||||
|
||||
result = <string[]>_.pluck(stoogesAges, 'name');
|
||||
result = <string[]>_(stoogesAges).pluck('name').value();
|
||||
|
||||
interface ABC {
|
||||
[index: string]: number;
|
||||
|
||||
Vendored
+16
@@ -3444,6 +3444,22 @@ declare module _ {
|
||||
property: string): any[];
|
||||
}
|
||||
|
||||
interface LoDashArrayWrapper<T> {
|
||||
/**
|
||||
* @see _.pluck
|
||||
**/
|
||||
pluck<T extends {}>(
|
||||
property: string): LoDashArrayWrapper<any>;
|
||||
}
|
||||
|
||||
interface LoDashObjectWrapper<T> {
|
||||
/**
|
||||
* @see _.pluck
|
||||
**/
|
||||
pluck<T extends {}>(
|
||||
property: string): LoDashArrayWrapper<any>;
|
||||
}
|
||||
|
||||
//_.reduce
|
||||
interface LoDashStatic {
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user