-
Notifications
You must be signed in to change notification settings - Fork 1
/
.eslintrc.js
42 lines (41 loc) · 1.07 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
import react from "eslint-plugin-react";
import stylisticJs from "@stylistic/eslint-plugin-js";
module.exports = {
env: {
browser: true,
node: true,
es6: true,
},
extends: ["eslint:recommended", "plugin:react/recommended", "plugin:storybook/recommended", "prettier"],
globals: {
Atomics: "readonly",
SharedArrayBuffer: "readonly",
},
parserOptions: {
ecmaFeatures: {
jsx: true,
},
ecmaVersion: 2018,
sourceType: "module",
},
plugins: {
react: react,
"@stylistic/js": stylisticJs,
},
rules: {
"react/prop-types": "off",
"@stylistic/js/indent": ["error", 2],
"@stylistic/js/object-curly-spacing": ["always"],
"linebreak-style": ["error", "unix", "windows"],
// quotes: ["error", "double"],
// semi: ['error', 'always'],
"block-scoped-var": "error",
camelcase: ["warn", {ignoreDestructuring: true}],
"max-len": [160, 2],
curly: "error",
"default-case": "error",
"default-param-last": "error",
eqeqeq: ["error", "smart"],
"func-style": ["error", "expression"],
},
};