Skip to content

Commit

Permalink
feat(base): Add unicorn/consistent-empty-array-spread rule
Browse files Browse the repository at this point in the history
  • Loading branch information
MorevM committed May 15, 2024
1 parent b238856 commit c57d901
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions configurations/base/plugins/unicorn.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ module.exports = {
// Reason for `off`: too much false-positive errors
'!unicorn/consistent-destructuring': 'off',

// Prefer consistent types when spreading a ternary in an array literal (autofixable)
// https://github.com/sindresorhus/eslint-plugin-unicorn/blob/main/docs/rules/consistent-empty-array-spread.md
'+unicorn/consistent-empty-array-spread': 'warn',

// Move function definitions to the highest possible scope
// https://github.com/sindresorhus/eslint-plugin-unicorn/blob/main/docs/rules/consistent-function-scoping.md
// Note: really not sure about that, let it be in warn for a while @todo:
Expand Down

0 comments on commit c57d901

Please sign in to comment.