A
A
Andrey Pike2021-04-11 00:18:47
Vue.js
Andrey Pike, 2021-04-11 00:18:47

What's the problem using ESLint and VSCode?

Hi all.

The problem is that in VSCode some styling errors are triggered, and when building (npm run serve or npm run build) - others. As a result, 10,000 warnings during assembly. npm run lint ---fix doesn't fix anything at all, says everything is fine.

.eslintrc.ts :

export default {
  'env': {
    'browser': true,
    'es2021': true,
  },
  'extends': [
    'plugin:vue/essential',
    '@vue/typescript',
    'google',
  ],
  'parserOptions': {
    'ecmaVersion': 12,
    'parser': '@typescript-eslint/parser',
    'sourceType': 'module',
  },
  'plugins': [
    'vue',
    '@typescript-eslint',
  ],
  'rules': {
    'object-curly-spacing': ['error', 'always'],
    'max-len': ['error', { 'code': 120 }],
    'require-jsdoc': 0,
    'semi': ['error', 'always'],
  },
}


VSCode does not see semi in any way, on the contrary, ';' considers it a mistake.
And npm run lint doesn't fix anything.

Killed a lot of time, but I can not understand the reason.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question