After restarting the nuxt.js server, the "layouts\default.vue" file will be reset
P粉521013123
P粉521013123 2023-08-26 22:08:17
0
1
440
<p>I'm currently trying to learn vue.js and nuxtjs server on localhost:3000. </p> <p>I found a problem, whenever I create a new <strong>"xxxx.vue"</strong> file in the "pages" directory or restart the nuxt.js server, the server generates A new <strong>"default.vue"</strong>file to replace my old file <strong>(in \layouts\default.vue)</strong>. </p> <p>How to solve this problem? Is there a way to stop it from generating a new file to replace it? Thank you so much! </p>
P粉521013123
P粉521013123

reply all(1)
P粉805931281

If you modify the .nuxt\layouts\default.vue file, it will be reset after the development server is restarted. If you want to modify the layout, please ignore this file and create (or copy) a layouts\default.vue file in your root directory and modify the file.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template