[Vuejs]-What's the appropriate way to replace my wrong design?

0đź‘Ť

âś…

Nuxt has a “router-view”. It is just: <nuxt />.

The way to go here, is to use layouts.

There is a default file in the layouts directory. Every page has this layout by default.

You can simply write in this default layout file your page structure.

For example:

<template>
  <Header />
  <nuxt />
  <Footer />
</template>

<script lang="ts">
import Vue from 'vue';
import Header from '..';
import Footer from '..';

export default {
  components: {
    Header,
    Footer,
  },
};
</script>

Leave a comment