/vue-unit-test-example

Example testing vue project built by Webpack with Karma and Istanbul

Primary LanguageJavaScript

Topics Covered

  • Using vue-loader with hot reload for development
  • Configuring Webpack loaders
  • Building for production with minification
  • Linting JavaScript inside *.vue files with ESLint
  • Testing *.vue components with Karma + Jasmine in Chrome
  • Coverage report with istanbul

Setup

# install dependencies
npm install

# serve with hot reload at localhost:8080
npm run dev

# build for production with minification
npm run build

# run unit tests
npm test