关于let的杂谈 一.块级作用域 二.let 是否存在变量提升 一.块级作用域 先来看段代码 { let a=1 } console.log(a); //出错, not defined { var a=1 } console.log(a