地沟油嘎嘎香
                                        Results
                                        2
                                        comments of
                                        
                                
                                            地沟油嘎嘎香
                                        
                                    @alanchanzm 1. `class` 声明会提升 . 是不是写错了? 原文: Class declarations, unlike function declarations, are not hoisted.
@alanchanzm 我觉得不对吧 ``` { const foo = new Foo(); // ReferenceError: Foo is not defined class Foo { constructor() { this.foo = 37; } } } ``` class会提升这段代码就说不过去! [class](http://es6.ruanyifeng.com/#docs/class)