ramda-adjunct 3.1.0 → 3.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.nvmrc +1 -1
- package/CHANGELOG.md +18 -0
- package/README.md +1 -1
- package/dist/RA.node.js +56 -5
- package/dist/RA.node.min.js +1 -1
- package/dist/RA.web.js +56 -5
- package/dist/RA.web.min.js +1 -1
- package/dist/RA.web.standalone.js +57 -5
- package/dist/RA.web.standalone.min.js +1 -1
- package/es/index.js +3 -0
- package/es/internal/ponyfills/Promise.any.js +3 -3
- package/es/isNotPrimitive.js +1 -0
- package/es/isPrimitive.js +1 -0
- package/es/isUinteger32.js +29 -0
- package/lib/index.js +7 -2
- package/lib/internal/ponyfills/Promise.any.js +3 -3
- package/lib/isNotPrimitive.js +1 -0
- package/lib/isPrimitive.js +1 -0
- package/lib/isUinteger32.js +38 -0
- package/package.json +24 -24
- package/src/index.js +2 -0
- package/src/isNotPrimitive.js +1 -0
- package/src/isPrimitive.js +1 -0
- package/src/isUinteger32.js +29 -0
- package/types/index.d.ts +1771 -1543
package/es/index.js
CHANGED
|
@@ -69,6 +69,9 @@ export { default as isInteger } from './isInteger';
|
|
|
69
69
|
export { default as isInteger32 } from './isInteger32';
|
|
70
70
|
export { default as isInt32 } from './isInteger32'; // alias of isInteger32
|
|
71
71
|
|
|
72
|
+
export { default as isUinteger32 } from './isUinteger32';
|
|
73
|
+
export { default as isUint32 } from './isUinteger32'; // alias of isUinteger32
|
|
74
|
+
|
|
72
75
|
export { default as isNotInteger } from './isNotInteger';
|
|
73
76
|
export { default as isBigInt } from './isBigInt';
|
|
74
77
|
export { default as isFloat } from './isFloat';
|
|
@@ -28,15 +28,15 @@ function _assertThisInitialized(self) { if (self === void 0) { throw new Referen
|
|
|
28
28
|
|
|
29
29
|
function _wrapNativeSuper(Class) { var _cache = typeof Map === "function" ? new Map() : undefined; _wrapNativeSuper = function _wrapNativeSuper(Class) { if (Class === null || !_isNativeFunction(Class)) return Class; if (typeof Class !== "function") { throw new TypeError("Super expression must either be null or a function"); } if (typeof _cache !== "undefined") { if (_cache.has(Class)) return _cache.get(Class); _cache.set(Class, Wrapper); } function Wrapper() { return _construct(Class, arguments, _getPrototypeOf(this).constructor); } Wrapper.prototype = Object.create(Class.prototype, { constructor: { value: Wrapper, enumerable: false, writable: true, configurable: true } }); return _setPrototypeOf(Wrapper, Class); }; return _wrapNativeSuper(Class); }
|
|
30
30
|
|
|
31
|
-
function _construct(Parent, args, Class) { if (_isNativeReflectConstruct()) { _construct = Reflect.construct; } else { _construct = function _construct(Parent, args, Class) { var a = [null]; a.push.apply(a, args); var Constructor = Function.bind.apply(Parent, a); var instance = new Constructor(); if (Class) _setPrototypeOf(instance, Class.prototype); return instance; }; } return _construct.apply(null, arguments); }
|
|
31
|
+
function _construct(Parent, args, Class) { if (_isNativeReflectConstruct()) { _construct = Reflect.construct.bind(); } else { _construct = function _construct(Parent, args, Class) { var a = [null]; a.push.apply(a, args); var Constructor = Function.bind.apply(Parent, a); var instance = new Constructor(); if (Class) _setPrototypeOf(instance, Class.prototype); return instance; }; } return _construct.apply(null, arguments); }
|
|
32
32
|
|
|
33
33
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
34
34
|
|
|
35
35
|
function _isNativeFunction(fn) { return Function.toString.call(fn).indexOf("[native code]") !== -1; }
|
|
36
36
|
|
|
37
|
-
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf
|
|
37
|
+
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
38
38
|
|
|
39
|
-
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
39
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
40
40
|
|
|
41
41
|
import { map } from 'ramda';
|
|
42
42
|
import resolveP from '../../resolveP';
|
package/es/isNotPrimitive.js
CHANGED
|
@@ -4,6 +4,7 @@ import isPrimitive from './isPrimitive';
|
|
|
4
4
|
* Checks if value is not a primitive data type. There are 6 primitive data types: `string`, `number`, `bigint`, `boolean`, `undefined`, `symbol` and a special case of `null`.
|
|
5
5
|
*
|
|
6
6
|
* @func isNotPrimitive
|
|
7
|
+
* @memberOf RA
|
|
7
8
|
* @category Type
|
|
8
9
|
* @sig * -> Boolean
|
|
9
10
|
* @since {@link https://char0n.github.io/ramda-adjunct/2.32.0|v2.32.0}
|
package/es/isPrimitive.js
CHANGED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { curryN } from 'ramda';
|
|
2
|
+
import toUinteger32 from './toUinteger32';
|
|
3
|
+
/**
|
|
4
|
+
* Checks whether the passed value is an unsigned 32 bit integer.
|
|
5
|
+
*
|
|
6
|
+
* @func isUinteger32
|
|
7
|
+
* @aliases isUint32
|
|
8
|
+
* @memberOf RA
|
|
9
|
+
* @since {@link https://char0n.github.io/ramda-adjunct/3.2.0|v3.2.0}
|
|
10
|
+
* @category Type
|
|
11
|
+
* @sig * -> Boolean
|
|
12
|
+
* @param {*} val The value to test
|
|
13
|
+
* @return {boolean}
|
|
14
|
+
* @see {@link RA.toUinteger32|toUinteger32}
|
|
15
|
+
* @example
|
|
16
|
+
*
|
|
17
|
+
* RA.isUinteger32(0); //=> true
|
|
18
|
+
* RA.isUinteger32(2 ** 32 - 1); //=> true
|
|
19
|
+
*
|
|
20
|
+
* RA.isUinteger32(Infinity); //=> false
|
|
21
|
+
* RA.isUinteger32(NaN); //=> false
|
|
22
|
+
* RA.isUinteger32(-1); //=> false
|
|
23
|
+
* RA.isUinteger32(2 ** 32); //=> false
|
|
24
|
+
*/
|
|
25
|
+
|
|
26
|
+
var isUinteger32 = curryN(1, function (val) {
|
|
27
|
+
return toUinteger32(val) === val;
|
|
28
|
+
});
|
|
29
|
+
export default isUinteger32;
|
package/lib/index.js
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
exports.__esModule = true;
|
|
4
4
|
exports.isNotRegExp = exports.isNotPrimitive = exports.isNotPlainObject = exports.isNotPlainObj = exports.isNotPair = exports.isNotObjectLike = exports.isNotObject = exports.isNotObjLike = exports.isNotObj = exports.isNotNumber = exports.isNotNull = exports.isNotNilOrEmpty = exports.isNotNil = exports.isNotNaN = exports.isNotMap = exports.isNotInteger = exports.isNotGeneratorFunction = exports.isNotFunction = exports.isNotFloat = exports.isNotFinite = exports.isNotEmpty = exports.isNotDate = exports.isNotBoolean = exports.isNotAsyncFunction = exports.isNotArrayLike = exports.isNotArray = exports.isNonPositive = exports.isNonNegative = exports.isNonEmptyString = exports.isNonEmptyArray = exports.isNilOrEmpty = exports.isNegativeZero = exports.isNegative = exports.isNaturalNumber = exports.isNaN = exports.isMap = exports.isIterable = exports.isInvalidDate = exports.isInteger32 = exports.isInteger = exports.isInt32 = exports.isIndexed = exports.isGeneratorFunction = exports.isFunction = exports.isFloat = exports.isFinite = exports.isFalsy = exports.isFalse = exports.isEven = exports.isError = exports.isEmptyString = exports.isEmptyArray = exports.isDate = exports.isBoolean = exports.isBlank = exports.isBigInt = exports.isAsyncFunction = exports.isArrayLike = exports.isArray = exports.invokeArgs = exports.invoke = exports.included = exports.inRange = exports.fnull = exports.floor = exports.flattenProp = exports.flattenPath = exports.flattenDepth = exports.firstP = exports.findOr = exports.filterIndexed = exports.escapeRegExp = exports.ensureArray = exports.dropArgs = exports.divideNum = exports.dispatch = exports.delayP = exports.defaultWhen = exports.curryRightN = exports.curryRight = exports.copyKeys = exports.concatRight = exports.concatAll = exports.compact = exports.ceil = exports.catchP = exports.cata = exports.async = exports.argsPass = exports.appendFlipped = exports.anyP = exports.allUnique = exports.allSettledP = exports.allP = exports.allIdenticalTo = exports.allIdentical = exports.allEqualTo = exports.allEqual = exports.Y = exports.Identity = void 0;
|
|
5
|
-
exports.
|
|
6
|
-
exports.zipObjWith = exports.weaveLazy = exports.weave = exports.viewOr = exports.unzipObjWith = exports.trunc = exports.trimStart = exports.trimRight = exports.trimLeft = exports.trimEnd = exports.trimCharsStart = exports.trimCharsEnd = exports.toUinteger32 = exports.toUint32 = exports.toNumber = exports.toInteger32 = exports.toInt32 = exports.toArray = exports.thenCatchP = exports.subtractNum = exports.stubUndefined = exports.stubString = exports.stubObject = exports.stubObj = exports.stubNull = void 0;
|
|
5
|
+
exports.spreadPath = exports.sortByProps = exports.sortByPaths = exports.sliceTo = exports.sliceFrom = exports.skipTake = exports.sign = exports.sequencing = exports.seq = exports.round = exports.resolveP = exports.replaceAll = exports.repeatStr = exports.renameKeysWith = exports.renameKeys = exports.renameKeyWith = exports.rejectP = exports.reduceRightP = exports.reduceP = exports.reduceIndexed = exports.rangeStep = exports.propNotEq = exports.pickIndexes = exports.paths = exports.pathOrLazy = exports.pathNotEq = exports.padStart = exports.padEnd = exports.padCharsStart = exports.padCharsEnd = exports.overlaps = exports.omitIndexes = exports.omitBy = exports.notEqual = exports.notBoth = exports.notAllUnique = exports.notAllPass = exports.nor = exports.noop = exports.nonePass = exports.noneP = exports.neither = exports.nand = exports.move = exports.mergeProps = exports.mergeProp = exports.mergePaths = exports.mergePath = exports.mapIndexed = exports.list = exports.liftFN = exports.liftF = exports.lensTraverse = exports.lensSatisfies = exports.lensNotSatisfy = exports.lensNotEq = exports.lensIso = exports.lensEq = exports.lengthNotEq = exports.lengthLte = exports.lengthLt = exports.lengthGte = exports.lengthGt = exports.lengthEq = exports.lastP = exports.isValidNumber = exports.isValidDate = exports.isUndefined = exports.isUinteger32 = exports.isUint32 = exports.isTruthy = exports.isTrue = exports.isThenable = exports.isSymbol = exports.isString = exports.isSparseArray = exports.isSet = exports.isSentinelValue = exports.isSafeInteger = exports.isRegExp = exports.isPrototypeOf = exports.isPromise = exports.isPrimitive = exports.isPositiveZero = exports.isPositive = exports.isPlainObject = exports.isPlainObj = exports.isPair = exports.isOdd = exports.isObjectLike = exports.isObject = exports.isObjLike = exports.isObj = exports.isNumber = exports.isNull = exports.isNotValidNumber = exports.isNotValidDate = exports.isNotUndefined = exports.isNotString = exports.isNotSet = void 0;
|
|
6
|
+
exports.zipObjWith = exports.weaveLazy = exports.weave = exports.viewOr = exports.unzipObjWith = exports.trunc = exports.trimStart = exports.trimRight = exports.trimLeft = exports.trimEnd = exports.trimCharsStart = exports.trimCharsEnd = exports.toUinteger32 = exports.toUint32 = exports.toNumber = exports.toInteger32 = exports.toInt32 = exports.toArray = exports.thenCatchP = exports.subtractNum = exports.stubUndefined = exports.stubString = exports.stubObject = exports.stubObj = exports.stubNull = exports.stubArray = exports.spreadProp = void 0;
|
|
7
7
|
|
|
8
8
|
var _isNotUndefined = _interopRequireDefault(require("./isNotUndefined"));
|
|
9
9
|
|
|
@@ -221,6 +221,11 @@ var _isInteger2 = _interopRequireDefault(require("./isInteger32"));
|
|
|
221
221
|
exports.isInteger32 = _isInteger2["default"];
|
|
222
222
|
exports.isInt32 = _isInteger2["default"];
|
|
223
223
|
|
|
224
|
+
var _isUinteger = _interopRequireDefault(require("./isUinteger32"));
|
|
225
|
+
|
|
226
|
+
exports.isUinteger32 = _isUinteger["default"];
|
|
227
|
+
exports.isUint32 = _isUinteger["default"];
|
|
228
|
+
|
|
224
229
|
var _isNotInteger = _interopRequireDefault(require("./isNotInteger"));
|
|
225
230
|
|
|
226
231
|
exports.isNotInteger = _isNotInteger["default"];
|
|
@@ -39,15 +39,15 @@ function _assertThisInitialized(self) { if (self === void 0) { throw new Referen
|
|
|
39
39
|
|
|
40
40
|
function _wrapNativeSuper(Class) { var _cache = typeof Map === "function" ? new Map() : undefined; _wrapNativeSuper = function _wrapNativeSuper(Class) { if (Class === null || !_isNativeFunction(Class)) return Class; if (typeof Class !== "function") { throw new TypeError("Super expression must either be null or a function"); } if (typeof _cache !== "undefined") { if (_cache.has(Class)) return _cache.get(Class); _cache.set(Class, Wrapper); } function Wrapper() { return _construct(Class, arguments, _getPrototypeOf(this).constructor); } Wrapper.prototype = Object.create(Class.prototype, { constructor: { value: Wrapper, enumerable: false, writable: true, configurable: true } }); return _setPrototypeOf(Wrapper, Class); }; return _wrapNativeSuper(Class); }
|
|
41
41
|
|
|
42
|
-
function _construct(Parent, args, Class) { if (_isNativeReflectConstruct()) { _construct = Reflect.construct; } else { _construct = function _construct(Parent, args, Class) { var a = [null]; a.push.apply(a, args); var Constructor = Function.bind.apply(Parent, a); var instance = new Constructor(); if (Class) _setPrototypeOf(instance, Class.prototype); return instance; }; } return _construct.apply(null, arguments); }
|
|
42
|
+
function _construct(Parent, args, Class) { if (_isNativeReflectConstruct()) { _construct = Reflect.construct.bind(); } else { _construct = function _construct(Parent, args, Class) { var a = [null]; a.push.apply(a, args); var Constructor = Function.bind.apply(Parent, a); var instance = new Constructor(); if (Class) _setPrototypeOf(instance, Class.prototype); return instance; }; } return _construct.apply(null, arguments); }
|
|
43
43
|
|
|
44
44
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
45
45
|
|
|
46
46
|
function _isNativeFunction(fn) { return Function.toString.call(fn).indexOf("[native code]") !== -1; }
|
|
47
47
|
|
|
48
|
-
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf
|
|
48
|
+
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
49
49
|
|
|
50
|
-
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
50
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
51
51
|
|
|
52
52
|
var AggregatedError = /*#__PURE__*/function (_Error) {
|
|
53
53
|
_inherits(AggregatedError, _Error);
|
package/lib/isNotPrimitive.js
CHANGED
|
@@ -13,6 +13,7 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "d
|
|
|
13
13
|
* Checks if value is not a primitive data type. There are 6 primitive data types: `string`, `number`, `bigint`, `boolean`, `undefined`, `symbol` and a special case of `null`.
|
|
14
14
|
*
|
|
15
15
|
* @func isNotPrimitive
|
|
16
|
+
* @memberOf RA
|
|
16
17
|
* @category Type
|
|
17
18
|
* @sig * -> Boolean
|
|
18
19
|
* @since {@link https://char0n.github.io/ramda-adjunct/2.32.0|v2.32.0}
|
package/lib/isPrimitive.js
CHANGED
|
@@ -29,6 +29,7 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "d
|
|
|
29
29
|
* for definition of what sub-types comprise a primitive.
|
|
30
30
|
*
|
|
31
31
|
* @func isPrimitive
|
|
32
|
+
* @memberOf RA
|
|
32
33
|
* @category Type
|
|
33
34
|
* @sig * -> Boolean
|
|
34
35
|
* @since {@link https://char0n.github.io/ramda-adjunct/2.32.0|v2.32.0}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
exports.__esModule = true;
|
|
4
|
+
exports["default"] = void 0;
|
|
5
|
+
|
|
6
|
+
var _ramda = require("ramda");
|
|
7
|
+
|
|
8
|
+
var _toUinteger = _interopRequireDefault(require("./toUinteger32"));
|
|
9
|
+
|
|
10
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* Checks whether the passed value is an unsigned 32 bit integer.
|
|
14
|
+
*
|
|
15
|
+
* @func isUinteger32
|
|
16
|
+
* @aliases isUint32
|
|
17
|
+
* @memberOf RA
|
|
18
|
+
* @since {@link https://char0n.github.io/ramda-adjunct/3.2.0|v3.2.0}
|
|
19
|
+
* @category Type
|
|
20
|
+
* @sig * -> Boolean
|
|
21
|
+
* @param {*} val The value to test
|
|
22
|
+
* @return {boolean}
|
|
23
|
+
* @see {@link RA.toUinteger32|toUinteger32}
|
|
24
|
+
* @example
|
|
25
|
+
*
|
|
26
|
+
* RA.isUinteger32(0); //=> true
|
|
27
|
+
* RA.isUinteger32(2 ** 32 - 1); //=> true
|
|
28
|
+
*
|
|
29
|
+
* RA.isUinteger32(Infinity); //=> false
|
|
30
|
+
* RA.isUinteger32(NaN); //=> false
|
|
31
|
+
* RA.isUinteger32(-1); //=> false
|
|
32
|
+
* RA.isUinteger32(2 ** 32); //=> false
|
|
33
|
+
*/
|
|
34
|
+
var isUinteger32 = (0, _ramda.curryN)(1, function (val) {
|
|
35
|
+
return (0, _toUinteger["default"])(val) === val;
|
|
36
|
+
});
|
|
37
|
+
var _default = isUinteger32;
|
|
38
|
+
exports["default"] = _default;
|
package/package.json
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
"cookbook",
|
|
15
15
|
"functional"
|
|
16
16
|
],
|
|
17
|
-
"version": "3.
|
|
17
|
+
"version": "3.3.0",
|
|
18
18
|
"homepage": "https://github.com/char0n/ramda-adjunct",
|
|
19
19
|
"license": "BSD-3-Clause",
|
|
20
20
|
"repository": {
|
|
@@ -124,13 +124,13 @@
|
|
|
124
124
|
"ramda": ">= 0.28.0 <= 0.28.0"
|
|
125
125
|
},
|
|
126
126
|
"devDependencies": {
|
|
127
|
-
"@babel/cli": "7.
|
|
128
|
-
"@babel/core": "=7.
|
|
129
|
-
"@babel/plugin-transform-modules-commonjs": "=7.
|
|
130
|
-
"@babel/preset-env": "=7.
|
|
131
|
-
"@babel/register": "7.
|
|
132
|
-
"@commitlint/cli": "=
|
|
133
|
-
"@commitlint/config-conventional": "=
|
|
127
|
+
"@babel/cli": "7.18.10",
|
|
128
|
+
"@babel/core": "=7.19.1",
|
|
129
|
+
"@babel/plugin-transform-modules-commonjs": "=7.18.6",
|
|
130
|
+
"@babel/preset-env": "=7.19.1",
|
|
131
|
+
"@babel/register": "7.18.9",
|
|
132
|
+
"@commitlint/cli": "=17.1.2",
|
|
133
|
+
"@commitlint/config-conventional": "=17.1.0",
|
|
134
134
|
"assert": "=2.0.0",
|
|
135
135
|
"babel-loader": "=8.2.5",
|
|
136
136
|
"babel-plugin-annotate-pure-calls": "0.4.0",
|
|
@@ -139,45 +139,45 @@
|
|
|
139
139
|
"chai": "4.3.6",
|
|
140
140
|
"codecov": "3.8.3",
|
|
141
141
|
"conventional-changelog-cli": "2.2.2",
|
|
142
|
-
"core-js": "=3.
|
|
142
|
+
"core-js": "=3.25.1",
|
|
143
143
|
"docdash": "git+https://github.com/char0n/docdash.git#534b44382138a55dd8d93642c979e51e46471185",
|
|
144
144
|
"dtslint": "=4.2.1",
|
|
145
|
-
"eslint": "=8.
|
|
145
|
+
"eslint": "=8.23.1",
|
|
146
146
|
"eslint-config-airbnb-base": "=15.0.0",
|
|
147
147
|
"eslint-config-prettier": "=8.5.0",
|
|
148
148
|
"eslint-plugin-import": "=2.26.0",
|
|
149
|
-
"eslint-plugin-mocha": "=10.0
|
|
150
|
-
"eslint-plugin-prettier": "4.
|
|
149
|
+
"eslint-plugin-mocha": "=10.1.0",
|
|
150
|
+
"eslint-plugin-prettier": "4.2.1",
|
|
151
151
|
"eslint-plugin-ramda": "2.5.1",
|
|
152
152
|
"fantasy-land": "5.0.0",
|
|
153
153
|
"fantasy-laws": "=2.0.1",
|
|
154
154
|
"folktale": "=2.3.2",
|
|
155
|
-
"glob": "=8.0.
|
|
156
|
-
"husky": "
|
|
155
|
+
"glob": "=8.0.3",
|
|
156
|
+
"husky": "8.0.1",
|
|
157
157
|
"istanbul": "=0.4.5",
|
|
158
|
-
"jsdoc": "=3.6.
|
|
158
|
+
"jsdoc": "=3.6.11",
|
|
159
159
|
"jsverify": "0.8.4",
|
|
160
160
|
"license-cli": "1.1.6",
|
|
161
|
-
"lint-staged": "
|
|
162
|
-
"mocha": "=
|
|
161
|
+
"lint-staged": "13.0.3",
|
|
162
|
+
"mocha": "=10.0.0",
|
|
163
163
|
"mocha-junit-reporter": "2.0.2",
|
|
164
164
|
"mocha-multi-reporters": "1.5.1",
|
|
165
165
|
"monet": "0.9.3",
|
|
166
166
|
"nyc": "15.1.0",
|
|
167
|
-
"prettier": "=2.
|
|
167
|
+
"prettier": "=2.7.1",
|
|
168
168
|
"process": "=0.11.10",
|
|
169
169
|
"ramda": "=0.28.0",
|
|
170
170
|
"ramda-fantasy": "=0.8.0",
|
|
171
171
|
"regenerator-runtime": "=0.13.9",
|
|
172
172
|
"rimraf": "3.0.2",
|
|
173
173
|
"sanctuary-show": "3.0.0",
|
|
174
|
-
"sinon": "=
|
|
175
|
-
"terser-webpack-plugin": "5.3.
|
|
176
|
-
"testem": "=3.
|
|
174
|
+
"sinon": "=14.0.0",
|
|
175
|
+
"terser-webpack-plugin": "5.3.6",
|
|
176
|
+
"testem": "=3.9.0",
|
|
177
177
|
"tslint": "=6.1.3",
|
|
178
|
-
"typescript": "=4.
|
|
179
|
-
"webpack": "=5.
|
|
180
|
-
"webpack-cli": "4.
|
|
178
|
+
"typescript": "=4.8.3",
|
|
179
|
+
"webpack": "=5.74.0",
|
|
180
|
+
"webpack-cli": "4.10.0"
|
|
181
181
|
},
|
|
182
182
|
"browserslist": "> 0.25%, ie 10, ie 11, not op_mini all",
|
|
183
183
|
"tonicExampleFilename": "tonicExample.js",
|
package/src/index.js
CHANGED
|
@@ -63,6 +63,8 @@ export { default as isNotFinite } from './isNotFinite';
|
|
|
63
63
|
export { default as isInteger } from './isInteger';
|
|
64
64
|
export { default as isInteger32 } from './isInteger32';
|
|
65
65
|
export { default as isInt32 } from './isInteger32'; // alias of isInteger32
|
|
66
|
+
export { default as isUinteger32 } from './isUinteger32';
|
|
67
|
+
export { default as isUint32 } from './isUinteger32'; // alias of isUinteger32
|
|
66
68
|
export { default as isNotInteger } from './isNotInteger';
|
|
67
69
|
export { default as isBigInt } from './isBigInt';
|
|
68
70
|
export { default as isFloat } from './isFloat';
|
package/src/isNotPrimitive.js
CHANGED
|
@@ -6,6 +6,7 @@ import isPrimitive from './isPrimitive';
|
|
|
6
6
|
* Checks if value is not a primitive data type. There are 6 primitive data types: `string`, `number`, `bigint`, `boolean`, `undefined`, `symbol` and a special case of `null`.
|
|
7
7
|
*
|
|
8
8
|
* @func isNotPrimitive
|
|
9
|
+
* @memberOf RA
|
|
9
10
|
* @category Type
|
|
10
11
|
* @sig * -> Boolean
|
|
11
12
|
* @since {@link https://char0n.github.io/ramda-adjunct/2.32.0|v2.32.0}
|
package/src/isPrimitive.js
CHANGED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { curryN } from 'ramda';
|
|
2
|
+
|
|
3
|
+
import toUinteger32 from './toUinteger32';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Checks whether the passed value is an unsigned 32 bit integer.
|
|
7
|
+
*
|
|
8
|
+
* @func isUinteger32
|
|
9
|
+
* @aliases isUint32
|
|
10
|
+
* @memberOf RA
|
|
11
|
+
* @since {@link https://char0n.github.io/ramda-adjunct/3.2.0|v3.2.0}
|
|
12
|
+
* @category Type
|
|
13
|
+
* @sig * -> Boolean
|
|
14
|
+
* @param {*} val The value to test
|
|
15
|
+
* @return {boolean}
|
|
16
|
+
* @see {@link RA.toUinteger32|toUinteger32}
|
|
17
|
+
* @example
|
|
18
|
+
*
|
|
19
|
+
* RA.isUinteger32(0); //=> true
|
|
20
|
+
* RA.isUinteger32(2 ** 32 - 1); //=> true
|
|
21
|
+
*
|
|
22
|
+
* RA.isUinteger32(Infinity); //=> false
|
|
23
|
+
* RA.isUinteger32(NaN); //=> false
|
|
24
|
+
* RA.isUinteger32(-1); //=> false
|
|
25
|
+
* RA.isUinteger32(2 ** 32); //=> false
|
|
26
|
+
*/
|
|
27
|
+
const isUinteger32 = curryN(1, (val) => toUinteger32(val) === val);
|
|
28
|
+
|
|
29
|
+
export default isUinteger32;
|