1
0

is-number.js 245 B

1234567891011
  1. 'use strict';
  2. var toString = Object.prototype.toString
  3. , id = toString.call(1);
  4. module.exports = function (x) {
  5. return ((typeof x === 'number') ||
  6. ((x instanceof Number) ||
  7. ((typeof x === 'object') && (toString.call(x) === id))));
  8. };