Skip to content

Commit

Permalink
feat(basic): prefer non global object of node (#159)
Browse files Browse the repository at this point in the history
Co-authored-by: Anthony Fu <anthonyfu117@hotmail.com>
  • Loading branch information
zanminkian and antfu committed Apr 3, 2023
1 parent d1cd722 commit 502f6b0
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/eslint-config-basic/index.js
Expand Up @@ -49,6 +49,7 @@ module.exports = {
'antfu',
'no-only-tests',
'unused-imports',
'node',
],
settings: {
'import/resolver': {
Expand Down Expand Up @@ -315,6 +316,10 @@ module.exports = {
'operator-linebreak': ['error', 'before'],
'max-statements-per-line': ['error', { max: 1 }],

// node
// 'node/prefer-global/process': ['error', 'never'], // Not sure if we need it as we are using `process.env.NODE_ENV` a lot in front-end.
'node/prefer-global/buffer': ['error', 'never'],

// unicorns
// Pass error message when throwing errors
'unicorn/error-message': 'error',
Expand Down
1 change: 1 addition & 0 deletions packages/eslint-config-basic/package.json
Expand Up @@ -27,6 +27,7 @@
"eslint-plugin-markdown": "^3.0.0",
"eslint-plugin-n": "^15.7.0",
"eslint-plugin-no-only-tests": "^3.1.0",
"eslint-plugin-node": "^11.1.0",
"eslint-plugin-promise": "^6.1.1",
"eslint-plugin-unicorn": "^46.0.0",
"eslint-plugin-unused-imports": "^2.0.0",
Expand Down
29 changes: 29 additions & 0 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 502f6b0

Please sign in to comment.