.eslintrc.json 4.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243
  1. {
  2. "env": {
  3. "es6": true,
  4. "node": true
  5. },
  6. "extends": "eslint:recommended",
  7. "parserOptions": {
  8. "sourceType": "module"
  9. },
  10. "rules": {
  11. "accessor-pairs": 2,
  12. "array-bracket-spacing": [
  13. 2,
  14. "never"
  15. ],
  16. "array-callback-return": 2,
  17. "arrow-body-style": 2,
  18. "arrow-parens": 2,
  19. "arrow-spacing": 2,
  20. "block-scoped-var": 2,
  21. "block-spacing": 2,
  22. "brace-style": [
  23. 2,
  24. "1tbs"
  25. ],
  26. "callback-return": 0,
  27. "camelcase": 2,
  28. "comma-spacing": [
  29. 2,
  30. {
  31. "after": true,
  32. "before": false
  33. }
  34. ],
  35. "comma-style": [
  36. 2,
  37. "last"
  38. ],
  39. "complexity": 2,
  40. "computed-property-spacing": [
  41. 2,
  42. "never"
  43. ],
  44. "consistent-return": 0,
  45. "consistent-this": 2,
  46. "curly": 0,
  47. "default-case": 0,
  48. "dot-location": [
  49. 2,
  50. "property"
  51. ],
  52. "dot-notation": [
  53. 2,
  54. {
  55. "allowKeywords": true
  56. }
  57. ],
  58. "eol-last": 2,
  59. "func-names": 0,
  60. "func-style": [
  61. 2,
  62. "declaration"
  63. ],
  64. "generator-star-spacing": 2,
  65. "global-require": 2,
  66. "guard-for-in": 2,
  67. "handle-callback-err": 0,
  68. "id-blacklist": 2,
  69. "id-length": 0,
  70. "id-match": 2,
  71. "indent": 0,
  72. "init-declarations": 0,
  73. "jsx-quotes": 2,
  74. "key-spacing": 2,
  75. "keyword-spacing": [
  76. 2,
  77. {
  78. "after": true,
  79. "before": true
  80. }
  81. ],
  82. "linebreak-style": [
  83. 2,
  84. "unix"
  85. ],
  86. "lines-around-comment": 2,
  87. "max-depth": 2,
  88. "max-len": 0,
  89. "max-nested-callbacks": 2,
  90. "max-params": 2,
  91. "new-cap": 2,
  92. "new-parens": 2,
  93. "newline-after-var": 0,
  94. "newline-per-chained-call": 0,
  95. "no-alert": 2,
  96. "no-array-constructor": 2,
  97. "no-bitwise": 2,
  98. "no-caller": 2,
  99. "no-console": [
  100. "error",
  101. {
  102. "allow": [
  103. "log",
  104. "warn",
  105. "error"
  106. ]
  107. }
  108. ],
  109. "no-catch-shadow": 2,
  110. "no-confusing-arrow": 2,
  111. "no-continue": 2,
  112. "no-div-regex": 2,
  113. "no-else-return": 0,
  114. "no-eq-null": 0,
  115. "no-eval": 2,
  116. "no-extend-native": 2,
  117. "no-extra-bind": 2,
  118. "no-extra-label": 2,
  119. "no-extra-parens": 2,
  120. "no-floating-decimal": 2,
  121. "no-implicit-coercion": 2,
  122. "no-implicit-globals": 2,
  123. "no-implied-eval": 2,
  124. "no-inline-comments": 0,
  125. "no-inner-declarations": [
  126. 2,
  127. "functions"
  128. ],
  129. "no-invalid-this": 2,
  130. "no-iterator": 2,
  131. "no-label-var": 2,
  132. "no-labels": 2,
  133. "no-lone-blocks": 2,
  134. "no-lonely-if": 2,
  135. "no-loop-func": 2,
  136. "no-magic-numbers": 0,
  137. "no-mixed-requires": 2,
  138. "no-multi-spaces": 2,
  139. "no-multi-str": 2,
  140. "no-multiple-empty-lines": 2,
  141. "no-native-reassign": 2,
  142. "no-negated-condition": 0,
  143. "no-nested-ternary": 2,
  144. "no-new": 2,
  145. "no-new-func": 2,
  146. "no-new-object": 2,
  147. "no-new-require": 2,
  148. "no-new-wrappers": 2,
  149. "no-octal-escape": 2,
  150. "no-param-reassign": 0,
  151. "no-path-concat": 2,
  152. "no-plusplus": [
  153. 2,
  154. {
  155. "allowForLoopAfterthoughts": true
  156. }
  157. ],
  158. "no-process-env": 2,
  159. "no-process-exit": 2,
  160. "no-proto": 2,
  161. "no-restricted-imports": 2,
  162. "no-restricted-modules": 2,
  163. "no-restricted-syntax": 2,
  164. "no-return-assign": 2,
  165. "no-script-url": 2,
  166. "no-self-compare": 2,
  167. "no-sequences": 2,
  168. "no-shadow": 0,
  169. "no-shadow-restricted-names": 2,
  170. "no-spaced-func": 2,
  171. "no-sync": 0,
  172. "no-ternary": 0,
  173. "no-throw-literal": 2,
  174. "no-trailing-spaces": 2,
  175. "no-undef-init": 2,
  176. "no-undefined": 2,
  177. "no-underscore-dangle": 0,
  178. "no-unmodified-loop-condition": 2,
  179. "no-unneeded-ternary": 2,
  180. "no-unused-expressions": 2,
  181. "no-use-before-define": 0,
  182. "no-useless-call": 2,
  183. "no-useless-concat": 2,
  184. "no-useless-constructor": 2,
  185. "no-var": 0,
  186. "no-void": 2,
  187. "no-warning-comments": 0,
  188. "no-whitespace-before-property": 2,
  189. "no-with": 2,
  190. "object-curly-spacing": 2,
  191. "object-shorthand": 2,
  192. "one-var": 0,
  193. "one-var-declaration-per-line": 2,
  194. "operator-assignment": 2,
  195. "operator-linebreak": 2,
  196. "padded-blocks": 0,
  197. "prefer-arrow-callback": 0,
  198. "prefer-const": 0,
  199. "prefer-reflect": 2,
  200. "prefer-rest-params": 2,
  201. "prefer-spread": 2,
  202. "prefer-template": 0,
  203. "quote-props": 2,
  204. "quotes": 0,
  205. "radix": 2,
  206. "require-jsdoc": 0,
  207. "require-yield": 2,
  208. "semi": 0,
  209. "semi-spacing": [
  210. 2,
  211. {
  212. "after": true,
  213. "before": false
  214. }
  215. ],
  216. "sort-imports": 2,
  217. "sort-vars": 2,
  218. "space-before-blocks": 2,
  219. "space-before-function-paren": 2,
  220. "space-in-parens": [
  221. 2,
  222. "never"
  223. ],
  224. "space-infix-ops": 2,
  225. "space-unary-ops": 2,
  226. "spaced-comment": [
  227. 2,
  228. "always"
  229. ],
  230. "strict": 0,
  231. "template-curly-spacing": 2,
  232. "valid-jsdoc": 2,
  233. "vars-on-top": 0,
  234. "wrap-iife": 2,
  235. "wrap-regex": 2,
  236. "yield-star-spacing": 2,
  237. "yoda": [
  238. 2,
  239. "never"
  240. ]
  241. }
  242. }