This repository has been archived by the owner on Sep 26, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 83
/
.eslintrc.js
58 lines (58 loc) · 1.51 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
57
58
module.exports = {
parser: 'babel-eslint',
parserOptions: {
ecmaVersion: 2020,
sourceType: 'module',
},
env: {
es6: true,
browser: true,
node: true,
},
plugins: ['svelte3'],
overrides: [
{
files: ['**/*.svelte'],
processor: 'svelte3/svelte3',
rules: {
'import/first': 'off',
'import/no-duplicates': 'off',
'import/no-mutable-exports': 'off',
'import/prefer-default-export': 'off',
'import/order': 'off',
'prefer-destructuring': 'off',
},
},
{
files: ['**/tests/**/*.js'],
env: { jest: true },
rules: { 'import/no-unresolved': ['error', { ignore: ['^@s/'] }] },
},
{
files: ['packages/docs/**/*.{js,svelte}'],
rules: {
'import/no-extraneous-dependencies': 'off',
'import/prefer-default-export': 'off',
'import/no-unresolved': ['error', { ignore: ['^@sapper/', '^@/'] }],
'no-return-assign': ['error', 'except-parens'],
'no-param-reassign': ['error', { props: false }],
},
},
],
extends: ['eslint:recommended', 'airbnb-base'],
settings: { 'svelte3/ignore-styles': () => true },
rules: {
camelcase: 'off',
'object-curly-newline': [
'error',
{
ImportDeclaration: { consistent: true },
ExportDeclaration: { consistent: true },
},
],
'operator-linebreak': ['error', 'after'],
'no-nested-ternary': 'off',
'import/no-extraneous-dependencies': 'off',
'global-require': 'off',
},
};