用uniapp開發(fā)時經(jīng)常會遇見使用webview跳轉(zhuǎn)第三方頁面的情況,但有時頁面內(nèi)容會被遮擋,可以向webview內(nèi)注入js來控制
onReady() {
// #ifdef APP-PLUS
var currentWebview = this.$scope.$getAppWebview()
let wv = currentWebview.children()[0];
wv.evalJS("document.getElementById('J_loginIframe').style.height = '500px'");
// #endif
},