| 1 | import { FlatCompat } from "@eslint/eslintrc"; |
| 2 | import path from "node:path"; |
| 3 | import { fileURLToPath } from "node:url"; |
| 4 | |
| 5 | const __filename = fileURLToPath(import.meta.url); |
| 6 | const __dirname = path.dirname(__filename); |
| 7 | |
| 8 | const compat = new FlatCompat({ |
| 9 | baseDirectory: __dirname, |
| 10 | }); |
| 11 | |
| 12 | const eslintConfig = [ |
| 13 | { |
| 14 | ignores: [ |
| 15 | "node_modules/**", |
| 16 | ".next/**", |
| 17 | ".open-next/**", |
| 18 | ".wrangler/**", |
| 19 | "out/**", |
| 20 | "build/**", |
| 21 | "dist/**", |
| 22 | "coverage/**", |
| 23 | "next-env.d.ts", |
| 24 | ], |
| 25 | }, |
| 26 | ...compat.extends("next/core-web-vitals", "next/typescript"), |
| 27 | { |
| 28 | rules: { |
| 29 | // Bilingual CJK content uses curly quotes intentionally |
| 30 | "react/no-unescaped-entities": "off", |
| 31 | }, |
| 32 | }, |
| 33 | ]; |
| 34 | |
| 35 | export default eslintConfig; |
| 36 |