javascript - 函数的非 ECMAscript 代码

标签 javascript ecmascript-6

我正在通读 ECMA Script 2015 specification .

functions 下,我看到:

In addition to its properties, a function contains executable code and state that determine how it behaves when invoked. A function’s code may or may not be written in ECMAScript (emphasis added).

什么情况下函数的代码不能用 ECMA 脚本编写?

最佳答案

执行环境提供的原生函数(如 StringArray 类,或 setTimeout,或浏览器 DOM)经常被用 C 编写(或由其他编写的函数提供支持)。

关于javascript - 函数的非 ECMAscript 代码,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32661777/

相关文章:

javascript - ES6 中带或不带大括号的导入

javascript - Robots.txt 拒绝 #!网址

javascript - 有没有办法从 IE 浏览器的输入字段中删除十字符号?

javascript - React-router 不会在不同路径上重新挂载组件

javascript - 通过 findIndex 方法比较 'id'

javascript - OLOO如何访问私有(private)变量

javascript - 仅使用 Y 数小于 X 的所有可能性?

javascript - 如何以粉丝专页而非用户的身份发布到 Facebook 粉丝专页

reactjs - 如何导入在 webpack 中创建的包?

javascript - 按给定字段值查找数组对象