uni-app中设置单个页面样式方法

uniapp中设置单个页面样式方法

单个页面应该在对应的.vue文件下面使用 但是 app有时无效

<style>
page {
      
      
background-color: #ccc;
}
</style>

解决 直接在style标签下面再写一个style标签解决

<style lang="less" scoped>
.class-name {
      
      
	color:'#000'
}
</style>
<style>
page {
      
      
background-color: #ccc;
}
</style>

猜你喜欢

转载自blog.csdn.net/weixin_53191752/article/details/131809961