MCPcopy Create free account
hub / github.com/dataease/SQLBot / toNumber

Function toNumber

frontend/public/swagger-ui-bundle.js:7824–7846  ·  view source on GitHub ↗
(s)

Source from the content-addressed store, hash-verified

7822 return !!s && ('object' == o || 'function' == o)
7823 }
7824 function toNumber(s) {
7825 if ('number' == typeof s) return s
7826 if (
7827 (function isSymbol(s) {
7828 return (
7829 'symbol' == typeof s ||
7830 ((function isObjectLike(s) {
7831 return !!s && 'object' == typeof s
7832 })(s) &&
7833 '[object Symbol]' == B.call(s))
7834 )
7835 })(s)
7836 )
7837 return NaN
7838 if (isObject(s)) {
7839 var o = 'function' == typeof s.valueOf ? s.valueOf() : s
7840 s = isObject(o) ? o + '' : o
7841 }
7842 if ('string' != typeof s) return 0 === s ? s : +s
7843 s = s.replace(a, '')
7844 var i = _.test(s)
7845 return i || w.test(s) ? x(s.slice(2), i ? 2 : 8) : u.test(s) ? NaN : +s
7846 }
7847 s.exports = function debounce(s, o, i) {
7848 var a,
7849 u,

Callers 1

Calls 4

isObjectFunction · 0.85
valueOfMethod · 0.80
replaceMethod · 0.80
xFunction · 0.70

Tested by

no test coverage detected