34 lines
835 B
JavaScript
34 lines
835 B
JavaScript
import { dirname } from "path";
|
|
import { fileURLToPath } from "url";
|
|
import { FlatCompat } from "@eslint/eslintrc";
|
|
|
|
const __filename = fileURLToPath(import.meta.url);
|
|
const __dirname = dirname(__filename);
|
|
|
|
const compat = new FlatCompat({
|
|
baseDirectory: __dirname,
|
|
});
|
|
|
|
// 코드 스타일, 안티패턴, 잠재적 버그 검사을 위한 ESLint 설정
|
|
// 타입과 무관한 문제 찾기 위해 Next.js 권장 설정 사용
|
|
const eslintConfig = [
|
|
...compat.extends("next/core-web-vitals", "next/typescript"),
|
|
{
|
|
ignores: [
|
|
"node_modules/**",
|
|
".next/**",
|
|
"out/**",
|
|
"build/**",
|
|
"next-env.d.ts",
|
|
],
|
|
},
|
|
{
|
|
rules: {
|
|
"@typescript-eslint/no-explicit-any": "warn", // 끄기 warn → off
|
|
"@typescript-eslint/no-unused-vars": "warn",
|
|
},
|
|
},
|
|
];
|
|
|
|
export default eslintConfig;
|