function F(){? ? this.i = 123;}F.prototype.prop = {constructor:F,a:{b:this.i}}var f = new F();console.log(f.prop.a.b);為什么this指向window,怎么可以讓this指向構(gòu)造函數(shù)中,獲取到123.
關(guān)于js中對(duì)象字面量的this指向問題
sumTre
2018-12-25 21:18:34