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

@aicore/libcommonutils

Package Overview
Dependencies
Maintainers
3
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@aicore/libcommonutils - npm Package Compare versions

Comparing version 1.0.7 to 1.0.8

2

package.json
{
"name": "@aicore/libcommonutils",
"version": "1.0.7",
"version": "1.0.8",
"description": "Common util libraries used by various modules. This library is created to prevent code duplication",

@@ -5,0 +5,0 @@ "main": "src/index.js",

@@ -39,2 +39,2 @@ /*

export {isNumber, isString} from './utils/common.js';
export {isNumber, isString, isObject, isBoolean} from './utils/common.js';

@@ -0,1 +1,2 @@

// @INCLUDE_IN_API_DOCS
/** This is a description of the isString function.

@@ -25,1 +26,36 @@ * This function checks if object is sting or not

}
/** This is a description of the isObject function.
* This function checks if object is valid JS Object or not
* @param {Object} object - Take any Object
* @return {boolean} - true if it is an Object false otherwise
* */
export function isObject(object) {
if (object == null) {
return false;
}
if (isString(object)) {
return false;
}
if (isBoolean(object)) {
return false;
}
if (isNumber(object)) {
return false;
}
return typeof object === 'object';
}
/** This is a description of the isBoolean function.
* This function checks if object is valid boolean Object or not
* @param {Object} boolean - Take any Object
* @return {boolean} - true if it is a valid boolean false otherwise
* */
export function isBoolean(boolean) {
if (boolean == null) {
return false;
}
return (typeof boolean === 'boolean' || boolean instanceof Boolean);
}
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