第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號安全,請及時綁定郵箱和手機(jī)立即綁定
已解決430363個問題,去搜搜看,總會有你想問的

javascript 函數(shù)返回的問題,請教各位高手。

javascript 函數(shù)返回的問題,請教各位高手。

fshang 2018-08-28 13:25:52
function aFun(){function _(arg){this.arg = arg;}_.prototype.testFun = function(){console.log('this is prototype testFun')};_.testFun2 = function(){console.log('this is testFunc2');}return _;};var afun = new aFun('123');console.log(afun instanceof aFun)afun.testFun2(); //可以調(diào)用afun.testFun(); //不是在原型鏈上么?,為啥不可以調(diào)用???,var aFun2 = (function (){function _(arg){this.arg = arg;}_.prototype.testFun = function(){console.log('this is prototype testFun')};_.testFun2 = function(){console.log('this is testFunc2');}return _;})();var afun2 = new aFun2('ddd');console.log(afun2 instanceof aFun2)afun2.testFun2(); //不可以調(diào)用,為啥?afun2.testFun(); //可以調(diào)用,為啥可以?(我要瘋了)
查看完整描述

目前暫無任何回答

  • 0 回答
  • 0 關(guān)注
  • 151 瀏覽
慕課專欄
更多

添加回答

舉報

0/150
提交
取消
微信客服

購課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動學(xué)習(xí)伙伴

公眾號

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號