vedees/webpack-template

Add vue router

ayoubkhan558-zz opened this issue · 3 comments

Please add vue router in it

Ill post article later about it. but its easy. same way like vue-cli

vue-router:

  1. install vue-router:
    npm install vue-router
  2. index.js will be:
    import Vue from 'vue'
    import VueRouter from 'vue-router'
    Vue.use(VueRouter)
  3. Main app.vue component will be:
<!-- route outlet -->
<!-- component matched by the route will render here -->
<router-view></router-view>
  1. Create nav:
   <!-- use router-link component for navigation. -->
   <!-- specify the link by passing the `to` prop. -->
   <!-- `<router-link>` will be rendered as an `<a>` tag by default -->
   <router-link to="/foo">Go to Foo</router-link>
   <router-link to="/bar">Go to Bar</router-link>

Follow it: docs

Please add vue router in it

up