last case

This commit is contained in:
johno
2018-12-14 09:42:36 -06:00
parent 7ec68334ae
commit 67fe66dba5
2 changed files with 6 additions and 4 deletions
+4 -3
View File
@@ -1133,11 +1133,12 @@ declare namespace R {
/**
* Given a target, this function checks a list for the target and returns a boolean.
* Given a string, this function checks for the string in another string and returns
* Given a string, this function checks for the string in another string or list and returns
* a boolean.
*/
includes(s: string, string: string): boolean;
includes(s: string): (string: string) => boolean;
includes(s: string, list: ReadonlyArray<string> | string): boolean;
includes(s: string): (list: ReadonlyArray<string> | string) => boolean;
includes<T>(target: T, list: ReadonlyArray<T>): boolean;
includes<T>(target: T): (list: ReadonlyArray<T>) => boolean;
+2 -1
View File
@@ -972,7 +972,8 @@ interface Obj {
});
() => {
R.includes('ba')('banana'); // => true
R.includes('ba', 'banana'); // => true
R.includes('ma', ['ma', 'ng', 'o']); // => true
R.includes('ba', 'kiwi'); // => false
R.includes(1)([2, 3, 5, 8]); // => false
R.includes(8, [1, 8, 9, 17]); // => true