Skip to content

Commit

Permalink
Add eslint-config-n to node presets #96
Browse files Browse the repository at this point in the history
  • Loading branch information
leroykorterink committed Nov 8, 2024
1 parent 340baa2 commit 9b057f8
Show file tree
Hide file tree
Showing 3 changed files with 147 additions and 2 deletions.
142 changes: 141 additions & 1 deletion package-lock.json

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

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-import": "^2.31.0",
"eslint-plugin-jsx-a11y": "^6.10.2",
"eslint-plugin-n": "^17.13.1",
"eslint-plugin-react": "^7.37.2",
"eslint-plugin-react-hooks": "^5.0.0",
"eslint-plugin-security": "^3.0.1",
Expand Down
6 changes: 5 additions & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import eslint from '@eslint/js';
import eslintConfigPrettier from 'eslint-config-prettier';
import eslintPluginImport from 'eslint-plugin-import';
import eslintPluginJsxA11y from 'eslint-plugin-jsx-a11y';
import eslintPluginNode from 'eslint-plugin-n';
import eslintPluginReact from 'eslint-plugin-react';
import eslintPluginReactHooks from 'eslint-plugin-react-hooks';
import eslintPluginSecurity from 'eslint-plugin-security';
Expand Down Expand Up @@ -109,7 +110,10 @@ const typescriptReact = [
];

/** @type {import('eslint').Linter.Config} */
const node = [eslintPluginSecurity.configs.recommended];
const node = [
eslintPluginNode.configs['flat/recommended'],
eslintPluginSecurity.configs.recommended,
];

/** @type {import('eslint').Linter.Config} */
const base = [
Expand Down

0 comments on commit 9b057f8

Please sign in to comment.