mirror of
https://github.com/wassname/DefinitelyTyped.git
synced 2026-09-09 11:13:57 +08:00
added _.runInContext definition
This commit is contained in:
@@ -742,6 +742,9 @@ var object = {
|
||||
result = <any>_.result(object, 'cheese');
|
||||
result = <any>_.result(object, 'stuff');
|
||||
|
||||
var tempObject = {};
|
||||
result = <typeof _>_.runInContext(tempObject);
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
var iceCream = { flavor: "chocolate" };
|
||||
|
||||
Vendored
+6
@@ -2772,6 +2772,12 @@ declare module _ {
|
||||
**/
|
||||
export function result(object: any, property: string): any;
|
||||
|
||||
/**
|
||||
* Create a new lodash function using the given context object.
|
||||
* @param context The context object
|
||||
* @returns The lodash function.
|
||||
**/
|
||||
export function runInContext(context: any): typeof _;
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user