1 | module.exports = {
|
2 | env: {
|
3 | es6: true,
|
4 | node: true,
|
5 | },
|
6 | plugins: ['prettier'],
|
7 | extends: 'eslint:recommended',
|
8 | parserOptions: {
|
9 | sourceType: 'module',
|
10 | },
|
11 | rules: {
|
12 | 'prettier/prettier': [
|
13 | 'error',
|
14 | {
|
15 | printWidth: 120,
|
16 |
|
17 | tabWidth: 2,
|
18 | useTabs: false,
|
19 | semi: false,
|
20 | singleQuote: true,
|
21 | trailingComma: 'es5',
|
22 | bracketSpacing: false,
|
23 | arrowParens: 'always',
|
24 | },
|
25 | ],
|
26 | indent: ['error', 2],
|
27 | 'linebreak-style': ['error', 'unix'],
|
28 | quotes: ['error', 'single'],
|
29 | semi: ['error', 'never'],
|
30 | 'no-console': 'off',
|
31 | 'prefer-const': [
|
32 | 'error',
|
33 | {
|
34 | destructuring: 'any',
|
35 | ignoreReadBeforeAssign: false,
|
36 | },
|
37 | ],
|
38 | 'no-var': 'error',
|
39 | },
|
40 | }
|