source: node_modules/ramda/src/includes.js@ d24f17c

main
Last change on this file since d24f17c was d24f17c, checked in by Aleksandar Panovski <apano77@…>, 15 months ago

Initial commit

  • Property mode set to 100644
File size: 938 bytes
RevLine 
[d24f17c]1var _includes =
2/*#__PURE__*/
3require("./internal/_includes.js");
4
5var _curry2 =
6/*#__PURE__*/
7require("./internal/_curry2.js");
8/**
9 * Returns `true` if the specified value is equal, in [`R.equals`](#equals)
10 * terms, to at least one element of the given list; `false` otherwise.
11 * Also works with strings.
12 *
13 * @func
14 * @memberOf R
15 * @since v0.26.0
16 * @category List
17 * @sig a -> [a] -> Boolean
18 * @param {Object} a The item to compare against.
19 * @param {Array} list The array to consider.
20 * @return {Boolean} `true` if an equivalent item is in the list, `false` otherwise.
21 * @see R.any
22 * @example
23 *
24 * R.includes(3, [1, 2, 3]); //=> true
25 * R.includes(4, [1, 2, 3]); //=> false
26 * R.includes({ name: 'Fred' }, [{ name: 'Fred' }]); //=> true
27 * R.includes([42], [[42]]); //=> true
28 * R.includes('ba', 'banana'); //=>true
29 */
30
31
32var includes =
33/*#__PURE__*/
34_curry2(_includes);
35
36module.exports = includes;
Note: See TracBrowser for help on using the repository browser.