uni-app - run to the built-in browser using IP address (Network) access (custom domain name)

foreword

By default, it can only be localhostaccessed , as shown in the following figure:
insert image description here

solution

Open the mainfest.jsonfile , add disableHostCheckthe property, set the value to true.

"h5": {
   
    
    
	"devServer": {
   
    
    
		"disableHostCheck": true
	}
}

Guess you like

Origin blog.csdn.net/weixin_44198965/article/details/123473889