-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.yml
90 lines (90 loc) · 2.2 KB
/
.eslintrc.yml
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
root: true
env:
browser: true
node: true
es6: true
jest/globals: true
parser: '@typescript-eslint/parser'
parserOptions:
# When Use TypeScript, Setting of Root Dir. ( To Find for tsconfig.json )
tsconfigRootDir: '.'
# When Use TypeScript, Import tsconfig Setting.
project: './tsconfig.json'
sourceType: module
ecmaFeatures:
jsx: true
plugins:
- '@typescript-eslint'
- import
- jest
- react
- react-hooks
- simple-import-sort
- testing-library
- jest-dom
settings:
react:
version: 'detect'
node:
tryExtensions:
- '.js'
- '.ts'
- '.jsx'
- '.tsx'
- '.json'
- '.node'
#
#
# Set Linting Rules Below.
extends:
- 'eslint:recommended'
- 'plugin:@typescript-eslint/recommended'
- 'plugin:testing-library/react'
- 'plugin:jest-dom/recommended'
- 'prettier'
# eslint-config-next config see. -> https://github.com/vercel/next.js/blob/canary/packages/eslint-config-next/index.js
- 'next'
rules:
indent: off
'@next/next/no-img-element': off # This rule is not used when using next export.
'@typescript-eslint/no-non-null-assertion': off
'@typescript-eslint/naming-convention': off
'@typescript-eslint/no-namespace': off
'@typescript-eslint/member-delimiter-style': off
'@typescript-eslint/no-empty-function': off
'@typescript-eslint/prefer-interface': off
'@typescript-eslint/explicit-function-return-type': warn
'@typescript-eslint/no-unused-vars':
- error
- varsIgnorePattern: '^AddIgnoreName'
'@typescript-eslint/no-implicit-any-catch':
- error
- allowExplicitAny: true
'max-classes-per-file':
- error
- 2
'no-bitwise':
- error
- allow:
- '~'
'import/order': off
'sort-keys': off
'no-multiple-empty-lines': off
'lines-between-class-members':
- error
- always
- exceptAfterSingleLine: true
'no-console': off
'unicorn/number-literal-case': off
'spaced-comment':
- error
- always
- markers:
- '/'
'react/react-in-jsx-scope': off
'react/prop-types': off
'react-hooks/rules-of-hooks': error
'react-hooks/exhaustive-deps': warn
'simple-import-sort/imports': error
'simple-import-sort/exports': error
'@typescript-eslint/ban-ts-comment': off