Re: [问题] javascript 函数的提升

楼主: mrbigmouth (大嘴先生)   2016-05-12 16:37:16
※ 引述《kisha024 (4545454554)》之铭言:
: 各位好
: 我是参考这里的资料
: http://fireqqtw.logdown.com/posts/258823-javascript-function-notes
: function one() {
: console.log('global one');
: }
: function two() {
: console.log('global two');
: }
: function hoistFun() {
: console.log(typeof one);
: console.log(typeof two);
: one();
: two();
: function one() {
: console.log('local one');
: }
: var two = function() {
: console.log('local two');
: }
: }
:

Links booklink

Contact Us: admin [ a t ] ucptt.com