Vue 2.7
+Vuetify
,Typescript
,Pinia
,Vite
for the frontend build tooling, instead of Vue Cli- Using
Composition API
syntax from Vue 2(see the official Script Setup documentation) - Pulling up API requests using
axios
Eslint
for code stylingPinia
for state management- Using the
NHTSA's vPIC API
3rd party library for API integration - // Unit tests with Vitest and Vue test utils
- // Cypress.io e2e tests (configured similarly to
vue-cli
) - // Cypress.io component tests
VSCode + Volar (and disable Vetur) + TypeScript Vue Plugin (Volar).
If the standalone TypeScript plugin doesn't feel fast enough to you, Volar has also implemented. You can enable it by the following steps:
- Disable the built-in TypeScript Extension
- Run
Extensions: Show Built-in Extensions
from VSCode's command palette - Find
TypeScript and JavaScript Language Features
, right click and selectDisable (Workspace)
- Run
- Reload the VSCode window by running
Developer: Reload Window
from the command palette.
See Vite Configuration Reference.
npm install --global yarn
yarn global add typescript
In a project, that contains a .env.example
file. You can use the below command to use these environment variables to run.
cp .env.example .env
yarn install
# Using npm
npm install
# Using Yarn
yarn
# Using npm
npm run dev
# Using Yarn
yarn dev
# Using npm
npm run build
# Using Yarn
yarn build
Run Unit Tests with Vitest
# Using npm
npm run test:unit
# Using Yarn
yarn test:unit
Run End-to-End Tests with Cypress
# Using npm
npm run build
npm run test:e2e # or `npm run test:e2e:ci` for headless testing
# Using Yarn
yarn build
yarn test:e2e
Lint with ESLint
# Using npm
npm run lint
# Using Yarn
yarn lint