vue-preprocessor

0.0.1 • Public • Published

vue-preprocessor

A Jest preprocessor to load .vue files in tests.

Installation

  1. add package you your project
  • yarn add --dev vue-preprocessor or npm install --saveDev vue-preprocessor
  1. modify your jest config transform properties:

    "jest": {
      "moduleFileExtensions": [
        "js",
        "vue"
      ],
      "transform": {
        "^.+\\.js$": "<rootDir>/node_modules/babel-jest",
        "^.+\\.vue$": "<rootDir>/node_modules/vue-preprocessor"
      }
    }
  2. Start writing test that can import *.vue components.

  3. Cover your files!

License: MIT

Package Sidebar

Install

npm i vue-preprocessor

Weekly Downloads

1

Version

0.0.1

License

MIT

Unpacked Size

897 kB

Total Files

556

Last publish

Collaborators

  • dweiss96