Files
vue-cli/packages/@vue/cli-plugin-eslint
Evan You 64b4515731 refactor: change default test directory name to "tests"
BREAKING CHANGE: all tests are now located in "tests" instead of "test"
close #877
2018-02-28 18:07:06 -05:00
..
2018-02-28 17:08:12 -05:00
2018-01-05 09:20:20 -05:00
2018-02-28 17:22:48 -05:00
2018-02-28 17:08:12 -05:00
2018-02-08 22:04:22 -05:00

@vue/cli-plugin-eslint

eslint plugin for vue-cli

Injected Commands

  • vue-cli-service lint

    Usage: vue-cli-service lint [options] [...files]
    
    Options:
    
      --format [formatter] specify formatter (default: codeframe)
      --no-fix             do not fix errors
    

    Lints and fixes files. If no specific files are given, it lints all files in src and test.

    Other ESLint CLI options are also supported.

Configuration

ESLint can be configured via .eslintrc or the eslintConfig field in package.json.

Lint-on-save during development with eslint-loader can be enabled with the lintOnSave option in vue.config.js:

module.exports = {
  lintOnSave: true
}

Installing in an Already Created Project

npm install -D @vue/cli-plugin-eslint
vue invoke eslint

Injected webpack-chain Rules

  • config.rule('eslint')
  • config.rule('eslint').use('eslint-loader')