-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.json
38 lines (38 loc) · 1.33 KB
/
.eslintrc.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
{
"extends": ["next/core-web-vitals", "plugin:@typescript-eslint/recommended"],
"plugins": ["import", "@typescript-eslint"],
"rules": {
"import/order": [
"error",
{
"groups": [
"builtin", // Node.js built-in modules (e.g., 'fs', 'path')
"external", // Packages from npm (e.g., 'react')
"internal", // Absolute imports (e.g., '@/components/SomeComponent')
"parent", // Relative imports from parent directories (e.g., '../../')
"sibling", // Relative imports from sibling directories (e.g., '../')
"index" // Import from index files (e.g., './')
],
"newlines-between": "always", // New line between each group
"pathGroups": [
{
"pattern": "@/domain/**", // Match your absolute imports
"group": "internal",
"position": "before"
},
{
"pattern": "@/**", // Match all absolute imports starting with "@"
"group": "internal",
"position": "before"
}
],
"pathGroupsExcludedImportTypes": ["builtin"],
"alphabetize": {
"order": "desc", // Alphabetical order within groups
"caseInsensitive": true // Case insensitive sorting
}
}
],
"@typescript-eslint/no-explicit-any": "off"
}
}