source: node_modules/ramda-adjunct/src/isFalse.js

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

Initial commit

  • Property mode set to 100644
File size: 931 bytes
Line 
1import { identical, curryN } from 'ramda';
2
3/**
4 * Checks if input value is the Boolean primitive `false`. Will return false for all values created
5 * using the `Boolean` function as a constructor.
6 *
7 * @func isFalse
8 * @memberOf RA
9 * @since {@link https://char0n.github.io/ramda-adjunct/2.6.0|v2.6.0}
10 * @category Type
11 * @sig * -> Boolean
12 * @param {*} val The value to test
13 * @return {boolean}
14 * @see {@link RA.isTrue|isTrue}, {@link RA.isTruthy|isTruthy}, {@link RA.isFalsy|isFalsy}
15 * @example
16 *
17 * RA.isFalse(false); // => true
18 * RA.isFalse(Boolean(false)); // => true
19 * RA.isFalse(true); // => false
20 * RA.isFalse(0); // => false
21 * RA.isFalse(''); // => false
22 * RA.isFalse(null); // => false
23 * RA.isFalse(undefined); // => false
24 * RA.isFalse(NaN); // => false
25 * RA.isFalse([]); // => false
26 * RA.isFalse(new Boolean(false)); // => false
27 */
28
29const isFalse = curryN(1, identical(false));
30
31export default isFalse;
Note: See TracBrowser for help on using the repository browser.