2026-05-08 13:35:00 +09:00
|
|
|
import globals from "globals"
|
|
|
|
|
import nextPlugin from "@next/eslint-plugin-next"
|
|
|
|
|
import prettier from "eslint-config-prettier/flat"
|
|
|
|
|
import tseslint from "typescript-eslint"
|
|
|
|
|
|
2026-05-18 20:55:59 +09:00
|
|
|
const nextCoreWebVitalsConfig = {
|
|
|
|
|
name: "next/core-web-vitals",
|
|
|
|
|
plugins: {
|
|
|
|
|
"@next/next": nextPlugin,
|
|
|
|
|
},
|
|
|
|
|
rules: {
|
|
|
|
|
...nextPlugin.configs.recommended.rules,
|
|
|
|
|
...nextPlugin.configs["core-web-vitals"].rules,
|
|
|
|
|
},
|
|
|
|
|
}
|
|
|
|
|
|
2026-05-08 13:35:00 +09:00
|
|
|
export default [
|
|
|
|
|
{
|
|
|
|
|
ignores: [".next/**", "out/**", "build/**", "next-env.d.ts"],
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
files: ["**/*.{js,mjs,cjs,ts,tsx,jsx}"],
|
|
|
|
|
languageOptions: {
|
2026-05-20 14:26:08 +09:00
|
|
|
parser: tseslint.parser,
|
2026-05-08 13:35:00 +09:00
|
|
|
ecmaVersion: "latest",
|
|
|
|
|
sourceType: "module",
|
|
|
|
|
globals: {
|
|
|
|
|
...globals.browser,
|
|
|
|
|
...globals.nodeBuiltin,
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
},
|
2026-05-18 20:55:59 +09:00
|
|
|
nextCoreWebVitalsConfig,
|
2026-05-08 13:35:00 +09:00
|
|
|
prettier,
|
|
|
|
|
]
|