通过动态绑定class ,来禁止遮罩层打开后页面滚动
<template>
<view :class="{content:show1}">//show1是判断遮罩层是否显示
</view>
</template>
//下面为禁止页面滑动
.content{
overflow: hidden;
position: fixed;
width: 100%;
}
通过动态绑定class ,来禁止遮罩层打开后页面滚动
<template>
<view :class="{content:show1}">//show1是判断遮罩层是否显示
</view>
</template>
//下面为禁止页面滑动
.content{
overflow: hidden;
position: fixed;
width: 100%;
}