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:
959 bytes
|
Line | |
---|
1 | import { complement } from 'ramda';
|
---|
2 |
|
---|
3 | import _isNaN from './isNaN';
|
---|
4 |
|
---|
5 | /**
|
---|
6 | * Checks whether the passed value is complement of `NaN` and its type is not `Number`.
|
---|
7 | *
|
---|
8 | * @func isNotNaN
|
---|
9 | * @memberOf RA
|
---|
10 | * @since {@link https://char0n.github.io/ramda-adjunct/0.6.0|v0.6.0}
|
---|
11 | * @category Type
|
---|
12 | * @sig * -> Boolean
|
---|
13 | * @param {*} val The value to test
|
---|
14 | * @return {boolean}
|
---|
15 | * @see {@link RA.isNaN|isNaN}
|
---|
16 | * @example
|
---|
17 | *
|
---|
18 | * RA.isNotNaN(NaN); // => false
|
---|
19 | * RA.isNotNaN(Number.NaN); // => false
|
---|
20 | * RA.isNotNaN(0 / 0); // => false
|
---|
21 | *
|
---|
22 | * RA.isNotNaN('NaN'); // => true
|
---|
23 | * RA.isNotNaN(undefined); // => true
|
---|
24 | * RA.isNotNaN({}); // => true
|
---|
25 | * RA.isNotNaN('blabla'); // => true
|
---|
26 | *
|
---|
27 | * RA.isNotNaN(true); // => true
|
---|
28 | * RA.isNotNaN(null); // => true
|
---|
29 | * RA.isNotNaN(37); // => true
|
---|
30 | * RA.isNotNaN('37'); // => true
|
---|
31 | * RA.isNotNaN('37.37'); // => true
|
---|
32 | * RA.isNotNaN(''); // => true
|
---|
33 | * RA.isNotNaN(' '); // => true
|
---|
34 | */
|
---|
35 | const isNotNaN = complement(_isNaN);
|
---|
36 |
|
---|
37 | export default isNotNaN;
|
---|
Note:
See
TracBrowser
for help on using the repository browser.