Skip to content

Commit

Permalink
'解决部分机型打开白屏的问题'
Browse files Browse the repository at this point in the history
  • Loading branch information
lujiehui committed Oct 28, 2019
1 parent ed0c910 commit f4249df
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

### 项目初衷

作为前端开发工程师,日常开发中遇到H5的开发我们需要做不少的准备工作,例如Vant按需引入、Rem适配、注册vuex/vue-router、封装axios、svg图标的处理等等,开发中难免遇到后端同学接口不及时,又要去配置自己的mock server,配置完mock server又要花时间写上拉加载,下拉刷新等功能,后期又需要处理CDN、sourcemap、性能分析等等。这些工作繁琐费时,那不如来开发一个H5的通用架子吧,希望能让前端同学能快速搭建完业务所需的H5架子
开发一个H5的通用架子,让前端同学开箱即用,迅速投入战斗

----

Expand Down
8 changes: 6 additions & 2 deletions src/App.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<template>
<div id="app">
<transition :name="transitionName">
<!-- <router-view class="router"></router-view> -->
<keep-alive v-if="$route.meta.keepAlive">
<router-view class="router"></router-view>
</keep-alive>
Expand All @@ -26,13 +27,16 @@ export default {
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
color: #2c3e50;
width: 100%;
height: 100%;
position: relative;
}
.router {
width: 100%;
height: 100%;
height: 100vh;
// height: 100vh;
overflow: scroll;
position: fixed;
position: absolute;
overflow: hidden !important;
overflow-y: auto !important;
-webkit-overflow-scrolling: touch;
Expand Down
2 changes: 1 addition & 1 deletion src/settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ module.exports = {
* @description Whether fix the header
*/
fixedHeader: false,
vconsole: false,
vconsole: true,

/**
* @type {boolean} true | false
Expand Down
1 change: 1 addition & 0 deletions src/style/common.scss
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
html, body {
width: 100%;
height: 100%;
overflow-x: hidden;
-webkit-overflow-scrolling:touch;
}
Expand Down

1 comment on commit f4249df

@limuen
Copy link

@limuen limuen commented on f4249df Oct 28, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

最主要的还是html,body里面的那个height的高度

Please sign in to comment.