mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-08-22 21:11:17 +00:00
Add some ESLint rules + minor changes (#3665)
Main point was to enable ESLint `dot-notation` and `no-unneeded-ternary` rules for more code consistency. I took the occasion to add two minor commits: - Fix a problem found by running `test:spelling - Minor dependency update It wouldn't be a problem if the PR didn't arrive in the next release, the changes are cosmetic.
This commit is contained in:
committed by
GitHub
parent
d41ce81469
commit
143dfd6b67
@@ -55,11 +55,12 @@ const config = [
|
||||
"@stylistic/semi": ["error", "always"],
|
||||
"@stylistic/space-before-function-paren": ["error", "always"],
|
||||
"@stylistic/spaced-comment": "off",
|
||||
"dot-notation": "error",
|
||||
eqeqeq: "error",
|
||||
"id-length": "off",
|
||||
"import/order": "error",
|
||||
"import/extensions": "error",
|
||||
"import/newline-after-import": "error",
|
||||
"import/order": "error",
|
||||
"init-declarations": "off",
|
||||
"jest/consistent-test-it": "warn",
|
||||
"jest/no-done-callback": "warn",
|
||||
@@ -78,6 +79,7 @@ const config = [
|
||||
"no-ternary": "off",
|
||||
"no-throw-literal": "error",
|
||||
"no-undefined": "off",
|
||||
"no-unneeded-ternary": "error",
|
||||
"no-unused-vars": "off",
|
||||
"no-useless-return": "error",
|
||||
"no-warning-comments": "off",
|
||||
@@ -112,7 +114,8 @@ const config = [
|
||||
"max-lines-per-function": ["error", 100],
|
||||
"no-magic-numbers": "off",
|
||||
"one-var": "off",
|
||||
"prefer-destructuring": "off"
|
||||
"prefer-destructuring": "off",
|
||||
"sort-keys": "error"
|
||||
}
|
||||
},
|
||||
{
|
||||
|
Reference in New Issue
Block a user