Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@hi-ui/type-assertion

Package Overview
Dependencies
Maintainers
2
Versions
24
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@hi-ui/type-assertion - npm Package Compare versions

Comparing version 4.0.0-alpha.11 to 4.0.0-alpha.12

12

lib/cjs/index.js

@@ -25,2 +25,10 @@ /** @LICENSE

/**
* Assert is Undefined
*/
var isUndef = function isUndef(arg) {
return arg === undefined;
};
/**
* Assert is Nullish

@@ -64,3 +72,3 @@ */

var isPromise = function isPromise(arg) {
return (isObjectLike(arg) || typeof arg === 'function') && typeof arg.then === 'function';
return isObjectLike(arg) && isFunction(arg.then);
};

@@ -113,5 +121,7 @@ /**

exports.isObject = isObject;
exports.isObjectLike = isObjectLike;
exports.isPromise = isPromise;
exports.isString = isString;
exports.isUndef = isUndef;
exports.isUndefined = isUndefined;
//# sourceMappingURL=index.js.map

@@ -20,2 +20,10 @@ import _typeof from "@babel/runtime/helpers/esm/typeof";

/**
* Assert is Undefined
*/
var isUndef = function isUndef(arg) {
return arg === undefined;
};
/**
* Assert is Nullish

@@ -59,3 +67,3 @@ */

var isPromise = function isPromise(arg) {
return (isObjectLike(arg) || typeof arg === 'function') && typeof arg.then === 'function';
return isObjectLike(arg) && isFunction(arg.then);
};

@@ -101,3 +109,3 @@ /**

export { isArray, isArrayNonEmpty, isElement, isFunction, isNullish, isNumeric, isObject, isPromise, isString, isUndefined };
export { isArray, isArrayNonEmpty, isElement, isFunction, isNullish, isNumeric, isObject, isObjectLike, isPromise, isString, isUndef, isUndefined };
//# sourceMappingURL=index.js.map

@@ -9,2 +9,6 @@ export declare type Dict<T = any> = Record<string, T>;

/**
* Assert is Undefined
*/
export declare const isUndef: (arg: unknown) => arg is void | undefined;
/**
* Assert is Nullish

@@ -14,2 +18,7 @@ */

/**
* Assert is an objectLike
* TODO: Assert the return type
*/
export declare const isObjectLike: (arg: unknown) => arg is any;
/**
* Assert is an object

@@ -16,0 +25,0 @@ */

4

package.json
{
"name": "@hi-ui/type-assertion",
"version": "4.0.0-alpha.11",
"version": "4.0.0-alpha.12",
"description": "A sub-package for @hi-ui/utils.",

@@ -48,3 +48,3 @@ "keywords": [],

},
"gitHead": "734a594a67ed76aa6e36772532e67b53048f2dae"
"gitHead": "37cbc875cd26474cfc9ddbd1eeb0abd797a31835"
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc