Switching Layouts in Nuxt
Published January 7, 2020
In Nuxt you can switch layouts in your pages by adding a layout: 'layout-name'
property in your page attributes. With projects that have consistent design, only using layouts for well, layouts, this is fine but there can be caveats to this.
Let's say when you log in, the user is redirected to a dashboard with a completely different design, Nuxt keeps the CSS of the default.vue
layout and the CSS of the components used in the layout.
Here are two things I've seen people use to work around the issue.