weex web获取html高度,weex 中的 web 标签如何控制高度?
我希望用 web 標簽來加載一個網頁,但是因為網頁比較長,所以如果我為web標簽指定了一個確定的高度,那么高度
以外的內容就無法顯示,并且web標簽也不支持滾動,也就是說我嵌入的頁面,部分內容是不可見的。有什么辦法可以
動態獲取web標簽的高度嗎?或者讓web標簽可以滾動。
------------------------ 更新
4 {{nodetype}}
.webview {
width: 750px;
height: 1200px;
}
import topcarousel from './components/topcarousel.vue';
import navbtn from './components/navbtn.vue';
import allsee from './components/allsee.vue';
import type from './components/type.vue';
import type2 from './components/type2.vue';
import topic from './components/topic.vue';
import unique from './components/unique.vue';
export default {
name: 'app',
data: {
weburl: 'http://www.1905.com/',
nodetype: 'init'
},
methods: {
calH: function(event) {
var that = this;
var node = weex.document.getRef('webview');
that.nodetype = node.type;
}
},
components: {
"topcarousel": topcarousel,
"navbtn": navbtn,
"allsee": allsee,
"type": type,
"type2": type2,
"topic": topic,
"unique": unique
}
};
weex 版本
------------------------- 更新
將 web 標簽內容移到 scroller 外邊就可以解決這個問題,最外層有 div 套一下。
總結
以上是生活随笔為你收集整理的weex web获取html高度,weex 中的 web 标签如何控制高度?的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 《永乐大典》高清影像数据库正式上线
- 下一篇: windows您的连接不是私密连接如何解