Files
vue-cli/packages/@vue/cli-plugin-eslint
Michał Sajnóg 7953d8300f feat: rework eslint configuration tab to display all rules (#2008)
* feat(cli-plugin-eslint): Add configuration tab

* chore(vue-cli-plugin-eslint): Add missing translations, extract UI descriptors

* fix(vue-cli-plugin-eslint): Import rules from CWD

* feat(vue-cli-plugin-eslint): Add uncategorized category, add tests

* test(vue-cli-plugin-eslint): Add missing tests

* fix(vue-cli-plugin-eslint): Escape html from rules' descriptions

* chore(vue-cli): Add --ci flag in tests

* chore(vue-cli-plugin-eslint): Remove snapshot
2018-08-01 11:40:29 +02:00
..
2018-07-30 18:19:07 -04:00
2018-03-20 01:39:26 +01:00
2018-07-30 18:19:13 -04: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
      --max-errors         specify number of errors to make build failed (default: 0)
      --max-warnings       specify number of warnings to make build failed (default: Infinity)
    

    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 is enabled by default. It can be disabled with the lintOnSave option in vue.config.js:

module.exports = {
  lintOnSave: false
}

Installing in an Already Created Project

vue add @vue/eslint

Injected webpack-chain Rules

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