mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-10-03 14:27:04 +00:00
Add applyTo
This commit is contained in:
Vendored
+7
@@ -242,6 +242,13 @@ declare namespace R {
|
||||
* the supplied arguments.
|
||||
*/
|
||||
applySpec<T>(obj: any): (...args: any[]) => T;
|
||||
|
||||
/**
|
||||
* Takes a value and applies a function to it.
|
||||
* This function is also known as the thrush combinator.
|
||||
*/
|
||||
applyTo<T, U>(el: T, fn: (t: T) => U): U;
|
||||
applyTo<T>(el: T): <U>(fn: (t: T) => U) => U;
|
||||
|
||||
/**
|
||||
* Makes an ascending comparator function out of a function that returns a value that can be compared with < and >.
|
||||
|
||||
Reference in New Issue
Block a user