Closed autumnfound closed 4 years ago
Looking into the Strongloop configuration, there is a mix of stylistic rule activations and some additional restrictions around some good practices in the node JS and ECMA.
Additionally, I've added the following rules:
Suggested final configuation:
{
"extends": [
"eslint:recommended",
"strongloop"
],
"env": {
"node": true,
"es2017": true,
"browser": false
},
"parser": "babel-eslint",
"ignorePatterns": [
"test/*.js",
"**/vendor/*.js"
],
"rules": {
"max-len": [1, 140, 2],
"eqeqeq": 1,
"complexity": [
"error"
],
"default-param-last": [
"error"
],
"no-magic-numbers": [
"error",
{
"ignore": [-1, 0],
"ignoreArrayIndexes": true
}
],
"arrow-parens": [
"error",
"as-needed"
]
}
}
In a recent patch, ESLint was added to provide better assurance of quality while building and running the script. To more quickly configure it, a configuration set was used to quickstart the linting configuration. The configuration should be more thoroughly checked to ensure that it meets our quality standards and conventions.