@1k/is-native 中文文档教程
@1k/is-native
测试值是否为本机函数。
Usage
npm i @1k/is-native
# yarn add @1k/is-native
const { isNative } = require('@1k/is-native')
console.log(isNative(Math.abs)) // true
console.log(isNative(() => void 0)) // false
console.log(isNative(1)) // false
console.log(isNative(NaN)) // false
<script src='https://unpkg.com/@1k/is-native'></script>
<script>
const { isNative } = OneK
console.log(isNative(Math.abs)) // true
console.log(isNative(() => void 0)) // false
console.log(isNative(1)) // false
console.log(isNative(NaN)) // false
</script>
License
MIT © 脚本力量
@1k/is-native
Test if a value is a native function.
Usage
npm i @1k/is-native
# yarn add @1k/is-native
const { isNative } = require('@1k/is-native')
console.log(isNative(Math.abs)) // true
console.log(isNative(() => void 0)) // false
console.log(isNative(1)) // false
console.log(isNative(NaN)) // false
<script src='https://unpkg.com/@1k/is-native'></script>
<script>
const { isNative } = OneK
console.log(isNative(Math.abs)) // true
console.log(isNative(() => void 0)) // false
console.log(isNative(1)) // false
console.log(isNative(NaN)) // false
</script>
License
MIT © Script Power