Yet another NPM package to improve upon JavaScript's typeof
operator.
npm install --save qc-type_of
Differences
Value | typeof | typeOf |
---|---|---|
arguments | 'object' | 'arguments' |
new Boolean(...) | 'object' | 'boolean' |
Infinity | 'number' | 'infinity' |
NaN | 'number' | 'nan' |
null | 'object' | 'null' |
new Number(...) | 'object' | 'number' |
new String(...) | 'object' | 'string' |