UNPKG

2.92 kBPlain TextView Raw
1{
2 "parser": "babel-eslint",
3 "extends": [
4 "eslint:recommended",
5 "plugin:react/recommended"
6 ],
7 "env": {
8 "browser": false,
9 "es6": true,
10 "node": true
11 },
12 "parserOptions": {
13 "sourceType": "module",
14 "ecmaFeatures": {
15 "jsx": true
16 }
17 },
18 "globals": {
19 "window": true,
20 "document": true,
21 "localStorage": true,
22 "sessionStorage": true,
23 "XMLHttpRequest": true
24 },
25 "plugins": [
26 "react"
27 ],
28 "settings": {
29 "react": {
30 "pragma": "React"
31 }
32 },
33 "rules": {
34 "arrow-parens": ["warn", "as-needed"],
35 "arrow-spacing": "warn",
36 "block-scoped-var": "warn",
37 "brace-style": [ "warn", "stroustrup", {
38 "allowSingleLine": true
39 }],
40
41 "comma-dangle": [ "warn", "always-multiline" ],
42 "comma-spacing": "warn",
43 "comma-style": "warn",
44
45 "curly": "warn",
46 "dot-notation": "warn",
47 "eol-last": "error",
48 "eqeqeq": "warn",
49
50 "func-call-spacing": [ "warn", "never" ],
51 "func-style": [ "error", "declaration", {
52 "allowArrowFunctions": true
53 }],
54 "generator-star-spacing": "warn",
55 "indent": [ "warn", 2, {
56 "MemberExpression": 0,
57 "SwitchCase": 1
58 }],
59 "jsx-quotes": "error",
60 "new-parens": "error",
61
62 "no-caller": "error",
63 "no-console": "off",
64 "no-duplicate-imports": "error",
65 "no-else-return": "warn",
66 "no-eval": "error",
67 "no-extra-label": "warn",
68 "no-floating-decimal": "warn",
69 "no-lonely-if": "warn",
70 "no-mixed-operators": "warn",
71 "no-multi-str": "error",
72 "no-negated-in-lhs": "warn",
73 "no-shadow": "warn",
74 "no-undef-init": "error",
75 "no-unused-expressions": "error",
76 "no-useless-computed-key": "warn",
77 "no-useless-constructor": "warn",
78 "no-useless-rename": "warn",
79 "no-useless-return": "warn",
80 "no-var": "error",
81 "no-whitespace-before-property": "warn",
82
83 "object-curly-spacing": [ "error", "always" ],
84 "prefer-const": "warn",
85 "prefer-rest-params": "warn",
86 "quote-props": [ "error", "as-needed" ],
87 "quotes": [ "warn", "single", {
88 "allowTemplateLiterals": true
89 }],
90
91 "rest-spread-spacing": ["warn", "never"],
92 "semi-spacing": "warn",
93 "semi-style": [ "warn", "last" ],
94 "semi": [ "error", "always" ],
95
96 "space-before-blocks": "warn",
97 "space-before-function-paren": "warn",
98 "space-infix-ops": "warn",
99 "space-in-parens": ["warn", "never"],
100 "spaced-comment": ["warn", "always"],
101 "template-curly-spacing": "warn",
102 "yield-star-spacing": "warn",
103
104 "valid-jsdoc": ["warn", {
105 "requireReturn": false,
106 "requireReturnDescription": false,
107 "requireParamDescription": false
108 }],
109
110 "react/display-name": "off",
111 "react/jsx-curly-spacing": "off",
112 "react/jsx-equals-spacing": "error",
113 "react/jsx-indent": [ "warn", 2 ],
114 "react/jsx-indent-props": [ "warn", 2 ],
115 "react/jsx-uses-react": "error",
116 "react/jsx-uses-vars": "error",
117 "react/jsx-tag-spacing": "warn",
118 "react/no-children-prop": "off",
119 "react/no-find-dom-node": "warn",
120 "react/no-unescaped-entities": "off",
121 "react/prop-types": "off"
122 }
123}