Sha256: 88804809e0d434a355da6e1c680f068734af5c24c89739fa311cbbc3c53a6246
Contents?: true
Size: 719 Bytes
Versions: 14
Compression:
Stored size: 719 Bytes
Contents
// takes a string and parses into an integer, but throws away commas first, to avoid truncation when there is a comma // use in place of javascript's native parseInt !function(global) { 'use strict'; var previousBlacklightRangeLimit = global.BlacklightRangeLimit; function BlacklightRangeLimit(options) { this.options = options || {}; } BlacklightRangeLimit.noConflict = function noConflict() { global.BlacklightRangeLimit = previousBlacklightRangeLimit; return BlacklightRangeLimit; }; BlacklightRangeLimit.parseNum = function parseNum(str) { str = String(str).replace(/[^0-9]/g, ''); return parseInt(str, 10); }; global.BlacklightRangeLimit = BlacklightRangeLimit; }(this);
Version data entries
14 entries across 14 versions & 1 rubygems