Skip to content

Commit

Permalink
fix: Add new unicorn rules (fixes #697)
Browse files Browse the repository at this point in the history
  • Loading branch information
freaktechnik committed Apr 22, 2023
1 parent 969d139 commit cbdd3eb
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
9 changes: 9 additions & 0 deletions packages/eslint-config-base/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,7 @@ module.exports = {
"no-async-promise-executor": 2,
"no-misleading-character-class": 2,
"no-prototype-builtins": 0,
"no-negated-condition": "warn",
"filenames/match-regex": [
2,
"^[a-z0-9-]+$"
Expand Down Expand Up @@ -352,6 +353,14 @@ module.exports = {
"unicorn/no-empty-file": "error",
"unicorn/no-useless-promise-resolve-reject": "error",
"unicorn/prefer-logical-operator-over-ternary": "error",
"unicorn/no-typeof-undefined": "error",
"unicorn/prefer-set-size": "error",
"unicorn/no-unnecessary-await": "warn",
"unicorn/no-useless-switch-case": "error",
"unicorn/prefer-modern-math-apis": "error",
"unicorn/no-unreadable-iife": "error",
"unicorn/prefer-native-coercion-functions": "warn",
"unicorn/no-useless-promsie-resolve-reject": "error",
"optimize-regex/optimize-regex": "warn"
},
settings: {
Expand Down
2 changes: 1 addition & 1 deletion packages/eslint-config-node/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ module.exports = {
"unicorn/prefer-node-protocol": "error",
"unicorn/prefer-module": "error",
"unicorn/no-invalid-remove-event-listener": "error",
"unicorn/prefer-json-parse-buffer": "warn",
"unicorn/prefer-json-parse-buffer": "error",
"import/no-unresolved": 0,
"node/no-missing-import": 0,
"unicorn/text-encoding-identifier-case": "error",
Expand Down

0 comments on commit cbdd3eb

Please sign in to comment.