由于需要对登录界面的body样式进行设置
在首页直接设置body{}实现不了
需要像这样设置:
export default {
beforeCreate: function() {
document.getElementsByTagName('body')[0].className = 'body-bg'
}
}
<style lang="scss">
.body-bg {
background-attachment: fixed;
overflow: hidden;
}
</style>