forked from curvefi/curve-frontend
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintrc.js
36 lines (36 loc) · 1.23 KB
/
.eslintrc.js
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
module.exports = {
root: true,
// This tells ESLint to load the config from the package `eslint-config-custom`
extends: ['custom'],
settings: {
next: {
rootDir: ['apps/*/', 'packages/ui/*/', 'packages/onboard-helpers/*/']
}
},
overrides: [
// enforce Feature Sliced rules for loan app (except 'pages' folder) and curve-lib
{
files: [
'apps/loan/src/{app,widgets,features,entities,shared}/**/*.{ts,tsx}',
'packages/curve-lib/src/shared/**/*.ts'
],
rules: {
'import/order': 'error', // feature-sliced/import-order
'import/no-internal-modules': 'error', // feature-sliced/public-api
'boundaries/element-types': 'error' // feature-sliced/layers-slices
}
},
// warn about Feature Sliced rules for main and lend apps, plus loan 'pages' folder
{
files: [
'apps/{main,lend}/src/{app,pages,widgets,features,entities,shared}/**/*.{ts,tsx}',
'apps/loan/src/pages/**/*.{ts,tsx}'
],
rules: {
'import/order': 'warn', // feature-sliced/import-order
'import/no-internal-modules': 'warn', // feature-sliced/public-api
'boundaries/element-types': 'warn' // feature-sliced/layers-slices
}
}
]
}