How to edit host and port?
Host 0.0.0.0
is designated to tell Nuxt to resolve a host address, which is accessible to connections outside of the host machine (e.g. LAN).
You can configure the connection variables in different ways. They are listed from highest to lowest priority.
Or
"scripts": {
"dev": "nuxt --hostname myhost --port 3333"
Inside your :
"scripts": {
"dev": "NUXT_HOST=0.0.0.0 NUXT_PORT=3333 nuxt"
}
Note: for better cross platform development support you can use cross-env package.
Installation:
"scripts": {
"dev": "cross-env NUXT_HOST=0.0.0.0 NUXT_PORT=3333 nuxt"
}
"host": "0.0.0.0",
"port": "3333"
}
},
"scripts": {
"dev": "nuxt"