两个webview嵌套在一起,A有顶部导航条,想通过A的导航条按钮触发B的事件,事件能触发,连B界面里dom的值都修改完成,并且console出来,但是就是没有改变显示。。。
A页面:
mui.plusReady(function(){
var content = plus.webview.getWebviewById('index._index.html');
menuBtn.addEventListener('tap',function(){
mui.fire(content,'refresh',{
key:'test'
});
})
});
B页面:
var h5 = document.querySelector('h5');
window.addEventListener('refresh',function(e){
console.log(h5.innerHTML);
h5.innerHTML = e.detail.key;
console.log(h5.innerHTML);
});
两次console出来结果都不一样,说明已经修改了,但是就是没有渲染出来

soloshadow
- 发布:2016-05-13 16:55
- 更新:2016-05-13 16:55
- 阅读:1181
fire触发事件不能操作dom
分类:MUI
0 个回复