0

I'm VERY new to ESLint, but I love the possibilities of using it as a tool. I have a folder in a Vue project that is the base for my project and I've configured linting for it. When I run it it lints great but I noticed one rule I didn't like was comma-dangle. After reading about it in their documentation I found what I thought was the correct rule so I opened my .eslintrc.js file and added the rule. My config file now looks like this:

module.exports = {
    "extends": "airbnb-base",
    "rules": {
        "comma-dangle": ["error", "never"]
    }
};

But when I save a file in my project (specifically my src/main.js or router/index.js) I still get an error that

Missing trailing comma
  src/router/index.js:12:28

Am I missing something? I also have a .eslintignore file that looks like this:

/build/
/config/
/dist/
/*.js
/test/unit/coverage/
ItsPronounced
  • 5,475
  • 13
  • 47
  • 86
  • Weird, I was playing around with the config file and closed my terminal and reopened, now it seems to be accepting the rule. Am I suppose to restart my terminal after each change to the config? – ItsPronounced Jul 16 '18 at 20:28
  • 1
    Yes - the dev server does not watch for changes in the config files, it only watches for changes inside your application folder. Unfortunately you have to restart it. – IVO GELOV Jul 17 '18 at 14:34

0 Answers0