We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
红宝书:闭包是指有权访问另外一个函数作用域中的变量的函数
MDN:闭包是指那些能够访问自由变量的函数--现在MDN已经修改闭包的定义
The text was updated successfully, but these errors were encountered:
在A作用域中使用的变量x,却没有在A作用域中声明(即在其他作用域中声明的),对于A作用域来说,x就是一个自由变量
let x = 6; function fn(){ let b=10; console.log(x+b); //x在这里就是一个自由变量 }
Sorry, something went wrong.
No branches or pull requests
定义
红宝书:闭包是指有权访问另外一个函数作用域中的变量的函数
MDN:闭包是指那些能够访问自由变量的函数--现在MDN已经修改闭包的定义
The text was updated successfully, but these errors were encountered: