Created
May 17, 2025 20:10
-
-
Save rbika/9b133e9c88431bad55f8d5e56daa1f59 to your computer and use it in GitHub Desktop.
ESLint config - Nextjs
This file contains hidden or 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
| import { dirname } from "path"; | |
| import { fileURLToPath } from "url"; | |
| import { FlatCompat } from "@eslint/eslintrc"; | |
| import prettier from "eslint-config-prettier"; | |
| const __filename = fileURLToPath(import.meta.url); | |
| const __dirname = dirname(__filename) | |
| const compat = new FlatCompat({ | |
| baseDirectory: __dirname, | |
| }); | |
| const eslintConfig = [ | |
| ...compat.extends("next/core-web-vitals", "next/typescript"), | |
| prettier | |
| ]; | |
| export default eslintConfig; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment