Skip to content

Commit

Permalink
Fix: disable unicorn/prefer-object-from-entries due to node-10 support
Browse files Browse the repository at this point in the history
  • Loading branch information
pustovitDmytro committed Sep 5, 2021
1 parent 86fb7d9 commit b5168d8
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 13 deletions.
2 changes: 1 addition & 1 deletion bin/test.sh
Expand Up @@ -7,7 +7,7 @@ DIRS=""
ROOT=$(pwd)
while read F ; do
cd $F
npx eslint -c $ROOT/lib/index.js --resolve-plugins-relative-to $ROOT src bin tests
npx eslint -c $ROOT/lib/index.js --resolve-plugins-relative-to $ROOT src bin tests --no-error-on-unmatched-pattern
DIRS="$DIRS $F"
done <$FILE
echo "Checked $DIRS"
26 changes: 14 additions & 12 deletions src/plugins/unicorn.js
@@ -1,18 +1,20 @@
const plugins = [ 'unicorn' ];
const recommended = [ 'plugin:unicorn/recommended' ];
const rules = {
'unicorn/no-unused-properties' : 2,
'unicorn/no-unsafe-regex' : 2,
'unicorn/prevent-abbreviations' : 0,
'unicorn/no-null' : 0,
'unicorn/prefer-node-protocol' : 0,
'unicorn/consistent-destructuring' : 0,
'unicorn/prefer-module' : 0,
'unicorn/no-process-exit' : 0, // duplicates base no-process-exit
'unicorn/no-array-for-each' : 0, // not usefull in chaining, bug with retur-continue
'unicorn/custom-error-definition' : 0,
'unicorn/prefer-array-flat' : 0, // not working for node 10,
'unicorn/prefer-prototype-methods' : 0,
'unicorn/no-unused-properties' : 2,
'unicorn/no-unsafe-regex' : 2,

'unicorn/prevent-abbreviations' : 0,
'unicorn/no-null' : 0,
'unicorn/prefer-node-protocol' : 0,
'unicorn/consistent-destructuring' : 0,
'unicorn/prefer-module' : 0,
'unicorn/no-process-exit' : 0, // duplicates base no-process-exit
'unicorn/no-array-for-each' : 0, // not usefull in chaining, bug with return-continue
'unicorn/custom-error-definition' : 0,
'unicorn/prefer-array-flat' : 0, // not working for node 10,
'unicorn/prefer-prototype-methods' : 0,
'unicorn/prefer-object-from-entries' : 0, // not working for node 10,

'unicorn/filename-case' : [
'error',
Expand Down

0 comments on commit b5168d8

Please sign in to comment.