/
.eslintrc.yaml
50 lines (48 loc) · 1.25 KB
/
.eslintrc.yaml
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
root: true
env:
es6: true
node: true
parserOptions:
ecmaVersion: 2018
sourceType: module
extends:
- eslint:recommended
- prettier
rules:
array-callback-return: error
camelcase: off
consistent-return: error
curly: [warn, multi-line, consistent]
eqeqeq: [error, smart]
no-constant-condition: [error, checkLoops: false]
no-implicit-globals: error
no-unused-vars: [warn, argsIgnorePattern: '^_']
no-useless-rename: error
prefer-const: [error, destructuring: all]
sort-imports: [warn, ignoreDeclarationSort: true]
overrides:
- files:
- test/browser/tests/*.js
env:
mocha: true
- files:
- '*.{ts,tsx}'
parser: '@typescript-eslint/parser'
plugins:
- '@typescript-eslint'
extends:
- plugin:@typescript-eslint/recommended
rules:
'@typescript-eslint/explicit-module-boundary-types': off
'@typescript-eslint/no-unused-vars': [warn, argsIgnorePattern: '^_']
- files:
- '**/*.test.{ts,tsx}'
- test/**/*.ts
rules:
'@typescript-eslint/ban-ts-comment': off
'@typescript-eslint/no-explicit-any': off
- files:
- 'packages/mf2-*/**/*.{ts,tsx}'
rules:
'@typescript-eslint/ban-types':
[error, { extendDefaults: true, types: { Function: false } }]