动态插入标签
addScript(){
let scriptArr = document.body.getElementsByTagName("script")
let runIn = true
for(var i in scriptArr ){
if(scriptArr[i].src == previewApi){
runIn = false
break;
}
}
if(runIn){
const s = document.createElement('script');
s.type = 'text/javascript';
s.src = previewApi;
document.body.appendChild(s);
}
}