MCPcopy Create free account
hub / github.com/Lemoncode/fonk / baseIsNative

Function baseIsNative

src/helpers/get.js:490–497  ·  view source on GitHub ↗

* The base implementation of `_.isNative` without bad shim checks. * * @private * @param {*} value The value to check. * @returns {boolean} Returns `true` if `value` is a native function, * else `false`.

(value)

Source from the content-addressed store, hash-verified

488 * else `false`.
489 */
490function baseIsNative(value) {
491 if (!isObject(value) || isMasked(value)) {
492 return false;
493 }
494 const pattern =
495 isFunction(value) || isHostObject(value) ? reIsNative : reIsHostCtor;
496 return pattern.test(toSource(value));
497}
498
499/**
500 * The base implementation of `_.toString` which doesn't convert nullish

Callers 1

getNativeFunction · 0.70

Calls 5

isObjectFunction · 0.70
isMaskedFunction · 0.70
isFunctionFunction · 0.70
isHostObjectFunction · 0.70
toSourceFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…