Merge pull request #25744 from deptno/ramda/bind

types/ramda fix bind definition & test code
This commit is contained in:
Ron Buckton
2018-05-18 14:27:33 -07:00
committed by GitHub
2 changed files with 5 additions and 1 deletions

View File

@@ -313,7 +313,7 @@ declare namespace R {
* Creates a function that is bound to a context. Note: R.bind does not provide the additional argument-binding
* capabilities of Function.prototype.bind.
*/
bind<T>(thisObj: T, fn: (...args: any[]) => any): (...args: any[]) => any;
bind<T>(fn: (...args: any[]) => any, thisObj: T): (...args: any[]) => any;
/**
* A function wrapping calls to the two functions in an && operation, returning the result of the first function

View File

@@ -2453,3 +2453,7 @@ class Why {
R.intersection([1, 2, 3], [2, 3, 3, 4]); // => [2, 3]
R.intersection([1, 2, 3])([2, 3, 3, 4]); // => [2, 3]
};
() => {
R.bind(console.log, console);
};