Search code examples
vue.jsnaming-conventionsdirectory-structure

Using naming best practices in Vue.JS, should I use `template` or `view`?


I’m organizing my VueJS project folder. Which is the better choice, templates or view? That is,

/src
- /templates
  - Home.vue
  - Login.vue
  - /users
    - User.vue

or

/src
- /view
  - Home.vue
  - Login.vue
  - /users
    - User.vue

Solution

  • The best practice is to use views for your routes and components for your dumb or intelligent components.

    Furthermore, I can suggest this article or this one.