forked from forem/forem
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintrc.js
40 lines (39 loc) · 986 Bytes
/
.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
/* eslint-env node */
module.exports = {
parser: '@babel/eslint-parser',
extends: [
'eslint:recommended',
'plugin:import/errors',
'plugin:import/warnings',
'plugin:cypress/recommended',
'prettier',
],
parserOptions: {
sourceType: 'module',
},
plugins: ['cypress', 'no-only-tests'],
rules: {
'import/order': ['error'],
'import/prefer-default-export': 'off',
'no-unused-vars': ['error', { argsIgnorePattern: '^_' }],
'prefer-const': ['error'],
'no-only-tests/no-only-tests': ['error', { fix: true }],
},
overrides: [
{
// Turn this rule off for barrel files
files: ['**/index.js'],
rules: {
'import/export': 'off',
'cypress/no-assigning-return-values': 'error',
'cypress/no-unnecessary-waiting': 'error',
'cypress/assertion-before-screenshot': 'warn',
'cypress/no-force': 'warn',
},
},
],
env: {
node: true,
'cypress/globals': true,
},
};