uniapp has no effect on the page selector on the app side

Problem : If you want to modify the page style in the page component, it can be displayed normally in h5 and mini programs, but it has no effect in the APP.

Reason : page is its parent node. If the style is scoped, it will be invalid.

Solution :

example

<style scoped>
	page{
    
    
		background-color: #f6f6f6;
	}
	img{
    
    
		user-drag: none;
	}
</style>

Change to

<style>
	page{
    
    
		background-color: #f6f6f6;
	}
</style>
<style scoped>
	img{
    
    
		user-drag: none;
	}
</style>

Guess you like

Origin blog.csdn.net/weixin_44646763/article/details/119239535#comments_27660367