How to cancel the default back button of the page in uni-app

insert image description here
The settings in the page.json page are as follows: Add autoBacButton: false

{
    
    
            "path" : "pages/newlogin/newlogin",
            "style" :                                                                                    
            {
    
    
                "navigationBarTitleText": "登录",
                "enablePullDownRefresh": false,
				"app-plus":{
    
    
					"titleNView":{
    
    
						"autoBackButton":false
					}
				}
				
            }
            
        }

If the above settings do not take effect, you can set as follows:

	onReady() {
    
    
			const a = document.getElementsByClassName('uni-page-head-hd')[0]
				a.style.display = 'none';
		},

insert image description here

Guess you like

Origin blog.csdn.net/qq_31676483/article/details/128888741