2 Star 11 Fork 2

www.tpframe.com / tpframe-uni-cms

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
App.vue 1007 Bytes
一键复制 编辑 原始数据 按行查看 历史
Frame 提交于 2022-03-08 10:24 . update
<script>
export default {
onLaunch: function() {
// #ifdef H5
// 强制手机模式浏览
if(uni.getSystemInfoSync()['windowWidth']>750){
this.timer = setInterval(()=>{
uni.showModal({
title:"温馨提醒",
content:"为了更好的体验,请用手机模式浏览",
showCancel:false,
success(res){
if (res.confirm) {
console.log('用户点击确定');
}
}
});
},200);
}
// #endif
console.log('App Launch');
let app = this.globalData;
app.$Helper = this.$Helper;
app.$Request = this.$Request;
// #ifdef APP-NVUE
var domModule = weex.requireModule('dom');
domModule.addRule('fontFace', {
'fontFamily': "tpf-iconfont'",
'src': "url('https://at.alicdn.com/t/font_2355434_q77jwdmovdd.ttf')"
});
// #endif
},
onShow: function() {
console.log('App Show')
},
onHide: function() {
console.log('App Hide')
}
}
</script>
<style>
/*每个页面公共css */
</style>
JavaScript
1
https://gitee.com/37duman/tpframe-uni-cms.git
git@gitee.com:37duman/tpframe-uni-cms.git
37duman
tpframe-uni-cms
tpframe-uni-cms
master

搜索帮助