Merge pull request #6020 from timramone/master

Made 'partial' generic
This commit is contained in:
Masahiro Wakame 2016-01-29 12:32:45 +09:00
commit 83ea7f2439
2 changed files with 2294 additions and 14 deletions

View File

@ -295,6 +295,10 @@ var exclaim = function (statement) { return statement + "!"; };
var welcome = _.compose(exclaim, greet);
welcome('moe');
var partialApplicationTestFunction = (a: string, b: number, c: boolean, d: string, e: number, f: string) => { }
var partialApplicationResult = _.partial(partialApplicationTestFunction, "", 1);
var parametersCanBeStubbed = _.partial(partialApplicationResult, _, _, _, "");
///////////////////////////////////////////////////////////////////////////////////////
_.keys({ one: 1, two: 2, three: 3 });
@ -462,7 +466,7 @@ function chain_tests() {
.flatten()
.find(num => num % 2 == 0)
.value();
var firstVal: number = _.chain([1, 2, 3])
.first()
.value();

File diff suppressed because it is too large Load Diff