@hi-ui/type-assertion
Advanced tools
Comparing version 4.0.0-alpha.3 to 4.0.0-alpha.5
@@ -46,12 +46,9 @@ /** @LICENSE | ||
var isArray = function isArray(arg) { | ||
return Array.isArray(arg); | ||
}; | ||
var isArray = Array.isArray; | ||
/** | ||
* Assert is an array but `length === 0` | ||
* Assert is an array and `array.length > 0` | ||
*/ | ||
var isEmptyArray = function isEmptyArray(arg) { | ||
return isArray(arg) && arg.length === 0; | ||
var isArrayNonEmpty = function isArrayNonEmpty(arg) { | ||
return isArray(arg) && arg.length > 0; | ||
}; | ||
@@ -68,3 +65,3 @@ /** | ||
exports.isArray = isArray; | ||
exports.isEmptyArray = isEmptyArray; | ||
exports.isArrayNonEmpty = isArrayNonEmpty; | ||
exports.isNumeric = isNumeric; | ||
@@ -71,0 +68,0 @@ exports.isObject = isObject; |
@@ -41,12 +41,9 @@ import _typeof from "@babel/runtime/helpers/esm/typeof"; | ||
var isArray = function isArray(arg) { | ||
return Array.isArray(arg); | ||
}; | ||
var isArray = Array.isArray; | ||
/** | ||
* Assert is an array but `length === 0` | ||
* Assert is an array and `array.length > 0` | ||
*/ | ||
var isEmptyArray = function isEmptyArray(arg) { | ||
return isArray(arg) && arg.length === 0; | ||
var isArrayNonEmpty = function isArrayNonEmpty(arg) { | ||
return isArray(arg) && arg.length > 0; | ||
}; | ||
@@ -62,3 +59,3 @@ /** | ||
export { isArray, isEmptyArray, isNumeric, isObject, isPromise }; | ||
export { isArray, isArrayNonEmpty, isNumeric, isObject, isPromise }; | ||
//# sourceMappingURL=index.js.map |
@@ -15,5 +15,5 @@ export declare type Dict<T = any> = Record<string, T>; | ||
/** | ||
* Assert is an array but `length === 0` | ||
* Assert is an array and `array.length > 0` | ||
*/ | ||
export declare const isEmptyArray: <T>(arg: unknown) => arg is T[] & { | ||
export declare const isArrayNonEmpty: <T>(arg: unknown) => arg is T[] & { | ||
length: 0; | ||
@@ -20,0 +20,0 @@ }; |
{ | ||
"name": "@hi-ui/type-assertion", | ||
"version": "4.0.0-alpha.3", | ||
"version": "4.0.0-alpha.5", | ||
"description": "A sub-package for @hi-ui/utils.", | ||
@@ -48,3 +48,3 @@ "keywords": [], | ||
}, | ||
"gitHead": "bfced541d76d7d69a7068c744a1023a7bc0d189f" | ||
"gitHead": "d2ea256c3b3726334a2091eba1de7321ed8d36e3" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
7658
125