修改APP.vue的内外边距
This commit is contained in:
parent
35463b2997
commit
a724363711
40
src/App.vue
40
src/App.vue
|
@ -1,6 +1,6 @@
|
||||||
<template>
|
<template>
|
||||||
<div id="app">
|
<div id="app" class="app1">
|
||||||
<router-view v-if="isRouterAlive"></router-view>
|
<router-view v-if="isRouterAlive"></router-view>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
@ -10,29 +10,35 @@
|
||||||
export default {
|
export default {
|
||||||
name: 'app',
|
name: 'app',
|
||||||
components: {
|
components: {
|
||||||
|
|
||||||
},
|
},
|
||||||
provide(){
|
provide() {
|
||||||
return{
|
return {
|
||||||
reload:this.reload
|
reload: this.reload
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data(){
|
data() {
|
||||||
return{
|
return {
|
||||||
isRouterAlive:true
|
isRouterAlive: true
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods:{
|
methods: {
|
||||||
reload(){
|
reload() {
|
||||||
this.isRouterAlive=false
|
this.isRouterAlive = false
|
||||||
this.$nextTick(()=>{
|
this.$nextTick(() => {
|
||||||
this.isRouterAlive=true
|
this.isRouterAlive = true
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style>
|
<style lang="scss">
|
||||||
|
.app1 {
|
||||||
|
// background-color: #269b33;
|
||||||
|
position: relative;
|
||||||
|
top: 0px;
|
||||||
|
margin: 0;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
Loading…
Reference in New Issue