Vue eslinrc.js giving error when trying to add semi rule

Viewed 1419

I have set up the basic Vue.js 2 Quickstart app. One of the things I wanted was eslint. It's nice, but as a Java developer not having a semicolin at the end of the line is blasphemy. So I add this rule like this to my .eslintrc.js file:

  // add your custom rules here
'rules': {
  'semi': "always",
  // allow paren-less arrow functions
  'arrow-parens': 0,
  // allow async-await
  'generator-star-spacing': 0,
  // allow debugger during development
  'no-debugger': process.env.NODE_ENV === 'production' ? 2 : 0
} 

However, when I save it, I am getting this error:

 Error: /asdf/code/vue/.eslintrc.js: Configuration for rule "semi" is invalid: Severity should be one of the following: 0 = off, 1 = warn, 2 = error (you passed '"always"').

which does not match the documentation here: ESLint Rules

I am using Atom if that makes a difference.

I did try an use a "0" but that did not actually fix atom telling me there is a semi-colon everywhere.

0 Answers
Related