在编程语言中,闭包(closure),又称为词法闭包(lexical closure)或函数闭包(function closure),是一种在具有一流函数的语言中(a language with first-class functions)实现词法作用域名称绑定的技术。从操作上来说,闭包是一个将函数…
1. 编译模式一定要设置为esnext,否则会报错: Strict MIME type checking is enforced for module scripts per HTML spec.Expected a JavaScript module script but the server responded with a MIME type of "text/plain". 具体解释可以看vi…