使用vue-cli構(gòu)建項(xiàng)目,在組件當(dāng)中import ueditor 初始化很慢,有時(shí)還會(huì)初始化失敗請(qǐng)問(wèn)有沒(méi)有遇到過(guò)類(lèi)似的問(wèn)題?能否提供解決思路或方案?發(fā)現(xiàn)每次初始化成功都會(huì)加載一些js、css文件,是否因?yàn)榧虞d文件網(wǎng)絡(luò)慢導(dǎo)致的?文件在本地服務(wù)器。very much Thanks in advance~~~<script id="content" class="content" type="text/plain"></script>created () { this.editor = UE.getEditor('content')
// test code
var d = 1
var dd = setInterval(function() {
d++ console.log(d)
}, 1000) this.editor.ready((editor) => { this.editor.execCommand('focus');
console.log('加載時(shí)間: ' + d + '秒');
clearInterval(dd)
})
},
destroyed () { this.editor.destroy()
}
ueditor初始化很慢,是需要加載相關(guān)文件?
阿晨1998
2018-10-18 13:18:16