zl程序教程

您现在的位置是:首页 >  前端

当前栏目

[Vue] Create Vue.js Layout and Navigation with Nuxt.js

VueJS and with create layout navigation Nuxt
2023-09-14 09:00:52 时间

Nuxt.js enables you to easily create layout and navigation by replacing the default App.vue template with your own _app.vue template. Then you simply surround your content with your navigation and/or layout and you're ready to go.

 

<!-- _app.vue -->

<template>
    <nuxt-container>
        <nav>
            <router-link class="button" to="/">
                Home page
            </router-link>
            <router-link class="button" to="/about">
                About page
            </router-link>
        </nav>
        <nuxt></nuxt>
        <footer>
            THis is the footer
        </footer>
    </nuxt-container>
</template>

 

Github