-
Notifications
You must be signed in to change notification settings - Fork 1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(deps-dev): update eslint to v9.17 (#1106)
- Loading branch information
1 parent
8d97b6b
commit c1d3d7e
Showing
4 changed files
with
824 additions
and
830 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
// @ts-check | ||
import tseslint from "typescript-eslint" | ||
import { FlatCompat } from "@eslint/eslintrc" | ||
import eslintPluginJsxA11y from "eslint-plugin-jsx-a11y" | ||
import eslintPluginReact from "eslint-plugin-react" | ||
|
||
const compat = new FlatCompat({ | ||
baseDirectory: import.meta.dirname, | ||
}) | ||
|
||
export default tseslint.config( | ||
tseslint.configs.recommended, | ||
...compat.config({ | ||
extends: ["next"], | ||
rules: { | ||
// react | ||
"react/prop-types": "off", | ||
"react/no-unescaped-entities": "off", | ||
"react/jsx-curly-brace-presence": "warn", | ||
|
||
// jsx-ally is already included in next-js so | ||
// we are adding only recommended rules directly here | ||
...eslintPluginJsxA11y.flatConfigs.recommended.rules, | ||
"jsx-a11y/no-onchange": "warn", | ||
|
||
// import | ||
"import/no-anonymous-default-export": "off", | ||
|
||
// next | ||
"@next/next/no-img-element": "off", | ||
}, | ||
}), | ||
// @ts-expect-error eslintPluginReact.configs.flat, but runtime is always defined | ||
eslintPluginReact.configs.flat["jsx-runtime"], | ||
{ | ||
linterOptions: { | ||
reportUnusedDisableDirectives: "error", | ||
}, | ||
rules: { | ||
// typescript | ||
"@typescript-eslint/explicit-function-return-type": "off", | ||
"@typescript-eslint/interface-name-prefix": "off", | ||
"@typescript-eslint/explicit-module-boundary-types": "off", | ||
}, | ||
} | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.