+1
-0
| export declare function isEmptyArray(x: any): boolean; | ||
| export declare function isNonEmptyArray(x: any): boolean; | ||
| export declare function isArrayOfArrays(x: any): boolean; | ||
@@ -3,0 +4,0 @@ export declare function isArrayOfBooleans(x: any): boolean; |
+8
-1
| "use strict"; | ||
| Object.defineProperty(exports, "__esModule", { value: true }); | ||
| exports.isArrayOfStrings = exports.isArrayOfObjects = exports.isArrayOfNumbers = exports.isArrayOfChars = exports.isArrayOfBooleans = exports.isArrayOfArrays = exports.isEmptyArray = void 0; | ||
| exports.isArrayOfStrings = exports.isArrayOfObjects = exports.isArrayOfNumbers = exports.isArrayOfChars = exports.isArrayOfBooleans = exports.isArrayOfArrays = exports.isNonEmptyArray = exports.isEmptyArray = void 0; | ||
| const basictypes_1 = require("./basictypes"); | ||
@@ -12,2 +12,9 @@ function isEmptyArray(x) { | ||
| exports.isEmptyArray = isEmptyArray; | ||
| function isNonEmptyArray(x) { | ||
| if ((0, basictypes_1.isArray)(x) && x.length > 0) { | ||
| return true; | ||
| } | ||
| return false; | ||
| } | ||
| exports.isNonEmptyArray = isNonEmptyArray; | ||
| function isArrayOfArrays(x) { | ||
@@ -14,0 +21,0 @@ if (!(0, basictypes_1.isArray)(x)) |
+2
-2
| export { isArray, isBoolean, isChar, isNumber, isObject, isString, isNull, isUndefined, isPrimitive, isReference, } from "./basictypes"; | ||
| export { isNotArray, isNotBoolean, isNotChar, isNotNumber, isNotObject, isNotString, isNotNull, isNotUndefined, isNotPrimitive, isNotReference, } from './inverses'; | ||
| export { hasAColon, isNumeric, isArrayIndex, isObjectKey, isFlag, isNotFlag, isSingleFlag, isDoubleFlag, isTripleFlag, } from './args'; | ||
| export { isEmptyArray, isArrayOfArrays, isArrayOfBooleans, isArrayOfChars, isArrayOfNumbers, isArrayOfObjects, isArrayOfStrings, } from './array'; | ||
| export { isEmptyObject, isObjectOfArrays, isObjectOfBooleans, isObjectOfChars, isObjectOfNumbers, isObjectOfObjects, isObjectOfStrings, } from './object'; | ||
| export { isEmptyArray, isNonEmptyArray, isArrayOfArrays, isArrayOfBooleans, isArrayOfChars, isArrayOfNumbers, isArrayOfObjects, isArrayOfStrings, } from './array'; | ||
| export { isEmptyObject, isNonEmptyObject, isObjectOfArrays, isObjectOfBooleans, isObjectOfChars, isObjectOfNumbers, isObjectOfObjects, isObjectOfStrings, } from './object'; | ||
| export { isLowerCase, isUpperCase, } from './strings'; | ||
| export { isHttp, isHttps, isURL, } from './urls'; |
+3
-1
| "use strict"; | ||
| Object.defineProperty(exports, "__esModule", { value: true }); | ||
| exports.isURL = exports.isHttps = exports.isHttp = exports.isUpperCase = exports.isLowerCase = exports.isObjectOfStrings = exports.isObjectOfObjects = exports.isObjectOfNumbers = exports.isObjectOfChars = exports.isObjectOfBooleans = exports.isObjectOfArrays = exports.isEmptyObject = exports.isArrayOfStrings = exports.isArrayOfObjects = exports.isArrayOfNumbers = exports.isArrayOfChars = exports.isArrayOfBooleans = exports.isArrayOfArrays = exports.isEmptyArray = exports.isTripleFlag = exports.isDoubleFlag = exports.isSingleFlag = exports.isNotFlag = exports.isFlag = exports.isObjectKey = exports.isArrayIndex = exports.isNumeric = exports.hasAColon = exports.isNotReference = exports.isNotPrimitive = exports.isNotUndefined = exports.isNotNull = exports.isNotString = exports.isNotObject = exports.isNotNumber = exports.isNotChar = exports.isNotBoolean = exports.isNotArray = exports.isReference = exports.isPrimitive = exports.isUndefined = exports.isNull = exports.isString = exports.isObject = exports.isNumber = exports.isChar = exports.isBoolean = exports.isArray = void 0; | ||
| exports.isURL = exports.isHttps = exports.isHttp = exports.isUpperCase = exports.isLowerCase = exports.isObjectOfStrings = exports.isObjectOfObjects = exports.isObjectOfNumbers = exports.isObjectOfChars = exports.isObjectOfBooleans = exports.isObjectOfArrays = exports.isNonEmptyObject = exports.isEmptyObject = exports.isArrayOfStrings = exports.isArrayOfObjects = exports.isArrayOfNumbers = exports.isArrayOfChars = exports.isArrayOfBooleans = exports.isArrayOfArrays = exports.isNonEmptyArray = exports.isEmptyArray = exports.isTripleFlag = exports.isDoubleFlag = exports.isSingleFlag = exports.isNotFlag = exports.isFlag = exports.isObjectKey = exports.isArrayIndex = exports.isNumeric = exports.hasAColon = exports.isNotReference = exports.isNotPrimitive = exports.isNotUndefined = exports.isNotNull = exports.isNotString = exports.isNotObject = exports.isNotNumber = exports.isNotChar = exports.isNotBoolean = exports.isNotArray = exports.isReference = exports.isPrimitive = exports.isUndefined = exports.isNull = exports.isString = exports.isObject = exports.isNumber = exports.isChar = exports.isBoolean = exports.isArray = void 0; | ||
| var basictypes_1 = require("./basictypes"); | ||
@@ -38,2 +38,3 @@ Object.defineProperty(exports, "isArray", { enumerable: true, get: function () { return basictypes_1.isArray; } }); | ||
| Object.defineProperty(exports, "isEmptyArray", { enumerable: true, get: function () { return array_1.isEmptyArray; } }); | ||
| Object.defineProperty(exports, "isNonEmptyArray", { enumerable: true, get: function () { return array_1.isNonEmptyArray; } }); | ||
| Object.defineProperty(exports, "isArrayOfArrays", { enumerable: true, get: function () { return array_1.isArrayOfArrays; } }); | ||
@@ -47,2 +48,3 @@ Object.defineProperty(exports, "isArrayOfBooleans", { enumerable: true, get: function () { return array_1.isArrayOfBooleans; } }); | ||
| Object.defineProperty(exports, "isEmptyObject", { enumerable: true, get: function () { return object_1.isEmptyObject; } }); | ||
| Object.defineProperty(exports, "isNonEmptyObject", { enumerable: true, get: function () { return object_1.isNonEmptyObject; } }); | ||
| Object.defineProperty(exports, "isObjectOfArrays", { enumerable: true, get: function () { return object_1.isObjectOfArrays; } }); | ||
@@ -49,0 +51,0 @@ Object.defineProperty(exports, "isObjectOfBooleans", { enumerable: true, get: function () { return object_1.isObjectOfBooleans; } }); |
+1
-0
| export declare function isEmptyObject(x: any): boolean; | ||
| export declare function isNonEmptyObject(x: any): boolean; | ||
| export declare function isObjectOfArrays(x: any): boolean; | ||
@@ -3,0 +4,0 @@ export declare function isObjectOfBooleans(x: any): boolean; |
+8
-1
| "use strict"; | ||
| Object.defineProperty(exports, "__esModule", { value: true }); | ||
| exports.isObjectOfStrings = exports.isObjectOfObjects = exports.isObjectOfNumbers = exports.isObjectOfChars = exports.isObjectOfBooleans = exports.isObjectOfArrays = exports.isEmptyObject = void 0; | ||
| exports.isObjectOfStrings = exports.isObjectOfObjects = exports.isObjectOfNumbers = exports.isObjectOfChars = exports.isObjectOfBooleans = exports.isObjectOfArrays = exports.isNonEmptyObject = exports.isEmptyObject = void 0; | ||
| const basictypes_1 = require("./basictypes"); | ||
@@ -12,2 +12,9 @@ function isEmptyObject(x) { | ||
| exports.isEmptyObject = isEmptyObject; | ||
| function isNonEmptyObject(x) { | ||
| if ((0, basictypes_1.isObject)(x) && Object.keys(x).length > 0) { | ||
| return true; | ||
| } | ||
| return false; | ||
| } | ||
| exports.isNonEmptyObject = isNonEmptyObject; | ||
| function isObjectOfArrays(x) { | ||
@@ -14,0 +21,0 @@ if (!(0, basictypes_1.isObject)(x)) |
+2
-0
@@ -48,2 +48,3 @@ { | ||
| {"name": "isEmptyArray", "description": "Returns `true` only if `arg` is an empty Array."}, | ||
| {"name": "isNonEmptyArray", "description": "Returns `true` only if `arg` is a non-empty Array."}, | ||
| {"name": "isArrayOfArrays", "description": "Returns `true` only if `arg` is an Array of Arrays."}, | ||
@@ -59,2 +60,3 @@ {"name": "isArrayOfBooleans", "description": "Returns `true` only if `arg` is an Array of Boolean values."}, | ||
| {"name": "isEmptyObject", "description": "Returns `true` only if `arg` is an empty Object."}, | ||
| {"name": "isNonEmptyObject", "description": "Returns `true` only if `arg` is a non-empty Object."}, | ||
| {"name": "isObjectOfArrays", "description": "Returns `true` only if `arg` is an Object only containing Array values."}, | ||
@@ -61,0 +63,0 @@ {"name": "isObjectOfBooleans", "description": "Returns `true` only if `arg` is an Object only containing Boolean values."}, |
+1
-1
| { | ||
| "name": "whichtype", | ||
| "version": "1.4.0", | ||
| "version": "1.5.0", | ||
| "description": "Whichtype is a small JavaScript library for checking the type of your variables.", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
+12
-9
@@ -77,2 +77,3 @@ | ||
| | `isEmptyArray(arg)` | Returns `true` only if `arg` is an empty Array. | | ||
| | `isNonEmptyArray(arg)` | Returns `true` only if `arg` is a non-empty Array. | | ||
| | `isArrayOfArrays(arg)` | Returns `true` only if `arg` is an Array of Arrays. | | ||
@@ -86,2 +87,3 @@ | `isArrayOfBooleans(arg)` | Returns `true` only if `arg` is an Array of Boolean values. | | ||
| | `isEmptyObject(arg)` | Returns `true` only if `arg` is an empty Object. | | ||
| | `isNonEmptyObject(arg)` | Returns `true` only if `arg` is a non-empty Object. | | ||
| | `isObjectOfArrays(arg)` | Returns `true` only if `arg` is an Object only containing Array values. | | ||
@@ -96,11 +98,12 @@ | `isObjectOfBooleans(arg)` | Returns `true` only if `arg` is an Object only containing Boolean values. | | ||
| ## Package details | ||
| | `Name` | `Value` | | ||
| | ------------- | ---------------------------------------------------------------------------------- | | ||
| | `Name` | `whichtype` | | ||
| | `Description` | `Whichtype is a small JavaScript library for checking the type of your variables.` | | ||
| | `Version` | `1.4.0` | | ||
| | `Author` | `iaseth` | | ||
| | `Homepage` | `https://github.com/iaseth/whichtype` | | ||
| | `Repository` | `iaseth/whichtype` | | ||
| | `License` | `MIT` | | ||
| | `Name` | `Value` | | ||
| | -------------- | ---------------------------------------------------------------------------------- | | ||
| | `Name` | `whichtype` | | ||
| | `Description` | `Whichtype is a small JavaScript library for checking the type of your variables.` | | ||
| | `Version` | `1.5.0` | | ||
| | `Author` | `iaseth` | | ||
| | `Homepage` | `https://github.com/iaseth/whichtype` | | ||
| | `Repository` | `iaseth/whichtype` | | ||
| | `License` | `MIT` | | ||
| | `Dependencies` | `0` | | ||
@@ -107,0 +110,0 @@ |
37277
3.79%554
3.94%150
2.04%