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

為了賬號(hào)安全,請(qǐng)及時(shí)綁定郵箱和手機(jī)立即綁定
已解決430363個(gè)問題,去搜搜看,總會(huì)有你想問的

js壓縮混淆后,其他文件怎么引用相關(guān)方法

js壓縮混淆后,其他文件怎么引用相關(guān)方法

德瑪西亞99 2018-12-12 14:18:24
1.壓縮前的js(function () {  var Test = function (name, age) {    this.name=name;    this.age=age;  }  Test.prototype={    getName:function () {      return this.name + ' haha';    }  }  var testA = new Test('xiao',12)  // 這里獲取得到 Test對(duì)象  console.log(testA.getName());})()2.壓縮后的js!function(){var e=function(e,n){this.name=e,this.age=n};e.prototype={getName:function(){return this.name+" haha"}};var n=new e("xiao",12);console.log(n.getName())}();3.在html中引入壓縮后的js后,var testA = new Test('xiao', 12)   // 這里找不到 Test對(duì)象  console.log(testA.getName());請(qǐng)問一下,js代碼壓縮前要怎么改寫才能解決這個(gè)問題?
查看完整描述

1 回答

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

添加回答

舉報(bào)

0/150
提交
取消
微信客服

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

幫助反饋 APP下載

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

公眾號(hào)

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