Something like this?
This is for ES6
{ "extends": "airbnb-base", "parserOptions": { "ecmaVersion": 6, "ecmaFeatures": { "impliedStrict": true } }, "env": { "browser": true, "es6": true } }
This is for ES5
{ "extends": "eslint:recommended", "parserOptions": { "ecmaVersion": 5, "ecmaFeatures": { "impliedStrict": true } }, "env": { "browser": true } }
I have an old project with mixed ES5 and ES6 files and they are linted by different .eslintrc.json, with something like this:
.eslintrc.json
eslint --fix --color --config .eslintrc.es5.json
The main problem is that the eslint config file is a yml file which is autocreated by yeoman. I couldn't use async await with that config.
Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment's permalink.
Hide child comments as well
Confirm
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Something like this?
This is for ES6
This is for ES5
I have an old project with mixed ES5 and ES6 files and they are linted by different
.eslintrc.json
, with something like this:The main problem is that the eslint config file is a yml file which is autocreated by yeoman. I couldn't use async await with that config.