fix: eslint error

This commit is contained in:
hamster1963 2024-12-13 15:37:04 +08:00
parent 74418c6ae5
commit 01ac9403e9
2 changed files with 11 additions and 25 deletions

11
.eslintrc.json Normal file
View File

@ -0,0 +1,11 @@
{
"extends": [
"next/core-web-vitals",
"next/typescript"
],
"rules": {
"@typescript-eslint/no-explicit-any": "off",
"@next/next/no-img-element": "off",
"react-hooks/exhaustive-deps": "off"
}
}

View File

@ -1,25 +0,0 @@
import js from "@eslint/js"
import globals from "globals"
import tseslint from "typescript-eslint"
export default tseslint.config(
{ ignores: [".next"] },
{
extends: [
js.configs.recommended,
...tseslint.configs.recommended,
"next/core-web-vitals",
"next/typescript",
],
files: ["**/*.{ts,tsx}"],
languageOptions: {
ecmaVersion: 2020,
globals: globals.browser,
},
rules: {
"@typescript-eslint/no-explicit-any": "off",
"@next/next/no-img-element": "off",
"react-hooks/exhaustive-deps": "off",
},
},
)