-
-
Notifications
You must be signed in to change notification settings - Fork 4
/
.eslintrc.js
56 lines (56 loc) · 1.42 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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
module.exports = {
extends: [
'eslint-config-ns-ts',
// @see https://nextjs.org/docs/basic-features/eslint
'plugin:@next/next/recommended'
],
rules: {
/**
* This rule was disabled because of NextJS' Link API.
*
* @see https://github.com/vercel/next.js/issues/5533#issuecomment-573287110
* @see https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/issues/402#issuecomment-368305051
*/
'jsx-a11y/anchor-is-valid': 0,
},
overrides: [
{
files: [
'./src/**/__stories__/*.stories.ts',
'./src/**/__stories__/*.stories.tsx',
],
rules: {
'global-require': 0,
'import/no-extraneous-dependencies': 0,
'max-classes-per-file': 0,
'no-console': 0,
},
},
/**
* exclude jest plugin in cypress files, because test are written
* differently and `expect` is typed different.
*/
{
files: [
'./cypress/**/*.ts',
'./cypress/**/*.tsx',
'./src/**/__cypress__/*.tsx',
],
extends: ['plugin:cypress/recommended'],
rules: {
'jest/expect-expect': 0,
'jest/valid-expect': 0,
'jest/valid-expect-in-promise': 0,
},
},
{
files: ['./scripts/**/*.js'],
rules: {
'global-require': 0,
'import/no-extraneous-dependencies': 0,
'no-console': 0,
'@typescript-eslint/no-var-requires': 0,
},
},
],
}