lodash: added _.add() method

This commit is contained in:
Ilya Mochalov
2015-08-13 01:33:45 +05:00
parent da995655d8
commit f3c213e2e3
2 changed files with 30 additions and 0 deletions
+8
View File
@@ -1086,6 +1086,14 @@ result = <Object>_([1]).toPlainObject();
result = <Object>_<string>([]).toPlainObject();
result = <Object>_({}).toPlainObject();
/********
* Math *
********/
// _.add
result = <number>_.add(1, 1);
result = <number>_(1).add(1);
/**********
* Objects *
***********/
+22
View File
@@ -5908,6 +5908,28 @@ declare module _ {
toPlainObject(value?: any): Object;
}
/********
* Math *
********/
//_.add
interface LoDashStatic {
/**
* Adds two numbers.
* @param augend The first number to add.
* @param addend The second number to add.
* @return Returns the sum.
*/
add(augend: number, addend: number): number;
}
interface LoDashWrapper<T> {
/**
* @see _.add
*/
add(addend: number): number;
}
/*************
* Objects *
*************/