A typescript boilerplate for Vue.js with Vue CLI 3.x that uses:
- vuex
- vue-router
- Element-UI
- i18n
- axios
- Font Awesome
- ...
- Node.js (npm)
-
Install Vue CLI 3.x
npm install -g @vue/cli # OR yarn global add @vue/cli
-
Install the dependencies
npm install # OR yarn install
This is the way I personally structure Vue.js projects. Feel free to modify it to fit your needs.
- ๐
assets
: Contains all assets such as images or sound files. - ๐
components
: Contains allVue
components. - ๐
layouts
: Contains allVue
-Layouts that can be set in thevue-router
. - ๐
models
: Contains all models needed for the business logic. - ๐
requests
: Contains all requests needed for communicating with the API. - ๐
rules
: Contains all reusable validation rules. - ๐
services
: Contains all services that fulfill web-requests. - ๐
store
: Contains all modules that are being used by thevuex
-store. - ๐
style
: Contains all stylesheets. - ๐
translations
: Contains all translations as.ts
files. - ๐
views
: Contains all views that are being used in thevue-router
.
npm run serve
# OR
yarn run serve
npm run build
# OR
yarn run build
npm run lint
# OR
yarn run lint