I've setting up ESLint for a legacy project that uses ES5, but the shareable configs all seem to be ES6. So after pulling in eslint recommended and google I've had to start adding extra config to prevent ES6 checks like no-var
. I was hoping that I wouldn't need to customize the recommended shareable configs too much so any updates can mostly come through shared configs without having to do a bunch of line-by-line comparisons.
Does anyone know where I can find recommended ES5 and Google ES5 configs for ESLint to be run over a Angular 1.x application?
This is an example of what I have so far, but it has no-var
ES6 config etc included so I've had to include it myself:
{
"env": {
"browser": true
},
"extends": ["eslint:recommended", "google"],
"parserOptions": {
"ecmaVersion": 5
},
"rules": {
"indent": ["error", 4, {"SwitchCase": 1}],
"linebreak-style": 0,
"padded-blocks": 0,
"quotes": ["error", "single"],
"semi": ["error", "always"],
"no-unused-vars": ["off"],
"valid-jsdoc": [
"error",
{
"prefer": {
"return": "returns"
},
"requireReturn": false,
"requireParamDescription": false,
"requireReturnDescription": false
}
],
"no-var": 0,
"func-call-spacing": 0
},
"globals": {
"angular": true,
"node": true
}
}