UNPKG

@technobuddha/library

Version:
17 lines (16 loc) 436 B
/** * Check to see if an object is a primitive * * @param input object to test * @returns true, if the object is a c */ export function isPrimitive(input) { return input === null || input === undefined || typeof input === 'string' || typeof input === 'number' || typeof input === 'bigint' || typeof input === 'boolean' || typeof input === 'symbol'; } export default isPrimitive;