router icon indicating copy to clipboard operation
router copied to clipboard

Documentation using modules

Open posva opened this issue 3 years ago • 3 comments

Right now the starting guide (https://next.router.vuejs.org/guide/) still uses a vanilla index.html approach. I think that it was easier back when vue-router started but now it isn't anymore and that maybe that page should be updated using .vue components and pointing to vue CLI and vite. It should maybe also point to Vue docs explaining Vue files.

What are your thoughts on this?

Do you have any other ideas on how to restructure this section of the docs?

posva avatar Mar 15 '21 21:03 posva

https://www.vuemastery.com/blog/vue-router-a-tutorial-for-vue-3/ Found an example about how to use router in Vite.

Stanley-SJTU avatar Apr 04 '21 20:04 Stanley-SJTU

starting a new vue3 + vite project, one thing that confused me was how to import the router in order to use the code from the getting started page. ( import * as VueRouter from 'vue-router seems to do the trick. )

the previous version's installation page had an example import statement, and that was a nice help.

ionous avatar Feb 03 '22 21:02 ionous

This was really painful, not having the imports needed for the examples on the router was quite confusing.

daniel-farina avatar Jun 02 '22 18:06 daniel-farina