-
Notifications
You must be signed in to change notification settings - Fork 894
/
.eslintrc
55 lines (51 loc) · 1.43 KB
/
.eslintrc
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
extends: yoast
root: true
parserOptions:
ecmaVersion: 2018
sourceType: module
settings:
react:
version: "18.2"
ignorePatterns:
- "packages/*/build/*"
rules:
no-prototype-builtins: 0
comma-dangle:
- error
- arrays: always-multiline
objects: always-multiline
imports: always-multiline
exports: always-multiline
functions: never
overrides:
- files:
- "packages/*/tests/**/*.js"
- "packages/*/spec/**/*.js"
# Temporary exclusion:
- "packages/components/a11y/tests/**/*.js"
env:
jest: true
rules:
no-restricted-imports: "off"
- files:
- "packages/components/**/*.js"
rules:
react/jsx-no-bind: 1
react/require-default-props: 1
react/default-props-match-prop-types: 1
react/no-unused-prop-types: 1
require-jsdoc: 1
import/no-unresolved: [ "error", { ignore: [ "^@yoast/(helpers|style-guide)" ] } ]
- files:
- "packages/social-metadata-forms/**/*.js"
rules:
import/no-unresolved: [ "error", { ignore: [ "^@yoast/(components|helpers|replacement-variable-editor|style-guide)" ] } ]
- files:
- "packages/social-metadata-previews/**/*.js"
rules:
import/no-unresolved: [ "error", { ignore: [ "^@yoast/(components|replacement-variable-editor|social-metadata-forms|style-guide)" ] } ]
- files:
- "packages/**/tests/**/*Test.js"
rules:
no-console: 0
react/jsx-no-bind: 0