@nex-ui/utils
Version:
Utility functions for React components.
9 lines (7 loc) • 471 B
JavaScript
const isNumber = (value)=>typeof value === 'number';
const isFunction = (value)=>typeof value === 'function';
const isPlainObject = (value)=>typeof value === 'object' && Object.prototype.toString.call(value) === '[object Object]';
const isString = (value)=>typeof value === 'string';
const isUndefined = (value)=>typeof value === 'undefined';
const isArray = (value)=>Array.isArray(value);
export { isArray, isFunction, isNumber, isPlainObject, isString, isUndefined };