Sha256: e4fe488a25ac3122fd6c0d36f2bebe41a632cab4e2cb87ee198e59e5c71aaaa6

Contents?: true

Size: 832 Bytes

Versions: 49

Compression:

Stored size: 832 Bytes

Contents

{"version":3,"file":"isNumeric.js","sourceRoot":"","sources":["../../src/util/isNumeric.ts"],"names":[],"mappings":";AAAA,wBAAwB,iBAAiB,CAAC,CAAA;AAE1C,mBAA0B,GAAQ;IAChC,oEAAoE;IACpE,mFAAmF;IACnF,uCAAuC;IACvC,+DAA+D;IAC/D,MAAM,CAAC,CAAC,iBAAO,CAAC,GAAG,CAAC,IAAI,CAAC,GAAG,GAAG,UAAU,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,CAAC;AAC3D,CAAC;AANe,iBAAS,YAMxB,CAAA;AAAA,CAAC","sourcesContent":["import { isArray } from '../util/isArray';\n\nexport function isNumeric(val: any): val is number {\n  // parseFloat NaNs numeric-cast false positives (null|true|false|\"\")\n  // ...but misinterprets leading-number strings, particularly hex literals (\"0x...\")\n  // subtraction forces infinities to NaN\n  // adding 1 corrects loss of precision from parseFloat (#15100)\n  return !isArray(val) && (val - parseFloat(val) + 1) >= 0;\n};\n"]}

Version data entries

49 entries across 49 versions & 4 rubygems

Version Path
ilog-0.4.1 node_modules/rxjs/util/isNumeric.js.map
ilog-0.4.0 node_modules/rxjs/util/isNumeric.js.map
ilog-0.3.3 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-18.0.0 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-17.21.0 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-17.20.0 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-17.19.1 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-17.19.0 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-17.18.0 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-17.17.0 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-17.16.0 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-17.15.0 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-17.14.0 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-17.13.0 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-17.12.2 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-17.12.1 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-17.12.0 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-17.11.0 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-17.10.0 node_modules/rxjs/util/isNumeric.js.map
govuk_publishing_components-17.9.0 node_modules/rxjs/util/isNumeric.js.map