.eslintrc 4.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177
  1. {
  2. "env": {
  3. "browser": true,
  4. "node": true
  5. },
  6. "ecmaFeatures": {
  7. "arrowFunctions": true,
  8. "destructuring": true,
  9. "classes": true,
  10. "defaultParams": true,
  11. "blockBindings": true,
  12. "modules": true,
  13. "objectLiteralComputedProperties": true,
  14. "objectLiteralShorthandMethods": true,
  15. "objectLiteralShorthandProperties": true,
  16. "restParams": true,
  17. "spread": true,
  18. "templateStrings": true
  19. },
  20. "rules": {
  21. "accessor-pairs": 2,
  22. "array-bracket-spacing": 0,
  23. "block-scoped-var": 0,
  24. "brace-style": [2, "1tbs", { "allowSingleLine": true }],
  25. "camelcase": 0,
  26. "comma-dangle": [2, "never"],
  27. "comma-spacing": [2, { "before": false, "after": true }],
  28. "comma-style": [2, "last"],
  29. "complexity": 0,
  30. "computed-property-spacing": 0,
  31. "consistent-return": 0,
  32. "consistent-this": 0,
  33. "constructor-super": 2,
  34. "curly": [2, "multi-line"],
  35. "default-case": 0,
  36. "dot-location": [2, "property"],
  37. "dot-notation": 0,
  38. "eol-last": 2,
  39. "eqeqeq": [2, "allow-null"],
  40. "func-names": 0,
  41. "func-style": 0,
  42. "generator-star-spacing": [2, { "before": true, "after": true }],
  43. "guard-for-in": 0,
  44. "handle-callback-err": [2, "^(err|error)$" ],
  45. "indent": [2, 2, { "SwitchCase": 1 }],
  46. "key-spacing": [2, { "beforeColon": false, "afterColon": true }],
  47. "linebreak-style": 0,
  48. "lines-around-comment": 0,
  49. "max-nested-callbacks": 0,
  50. "new-cap": [2, { "newIsCap": true, "capIsNew": false }],
  51. "new-parens": 2,
  52. "newline-after-var": 0,
  53. "no-alert": 0,
  54. "no-array-constructor": 2,
  55. "no-caller": 2,
  56. "no-catch-shadow": 0,
  57. "no-cond-assign": 2,
  58. "no-console": 0,
  59. "no-constant-condition": 0,
  60. "no-continue": 0,
  61. "no-control-regex": 2,
  62. "no-debugger": 2,
  63. "no-delete-var": 2,
  64. "no-div-regex": 0,
  65. "no-dupe-args": 2,
  66. "no-dupe-keys": 2,
  67. "no-duplicate-case": 2,
  68. "no-else-return": 0,
  69. "no-empty": 0,
  70. "no-empty-character-class": 2,
  71. "no-empty-label": 2,
  72. "no-eq-null": 0,
  73. "no-eval": 2,
  74. "no-ex-assign": 2,
  75. "no-extend-native": 2,
  76. "no-extra-bind": 2,
  77. "no-extra-boolean-cast": 2,
  78. "no-extra-parens": 0,
  79. "no-extra-semi": 0,
  80. "no-fallthrough": 2,
  81. "no-floating-decimal": 2,
  82. "no-func-assign": 2,
  83. "no-implied-eval": 2,
  84. "no-inline-comments": 0,
  85. "no-inner-declarations": [2, "functions"],
  86. "no-invalid-regexp": 2,
  87. "no-irregular-whitespace": 2,
  88. "no-iterator": 2,
  89. "no-label-var": 2,
  90. "no-labels": 2,
  91. "no-lone-blocks": 2,
  92. "no-lonely-if": 0,
  93. "no-loop-func": 0,
  94. "no-mixed-requires": 0,
  95. "no-mixed-spaces-and-tabs": 2,
  96. "no-multi-spaces": 2,
  97. "no-multi-str": 2,
  98. "no-multiple-empty-lines": [2, { "max": 1 }],
  99. "no-native-reassign": 2,
  100. "no-negated-in-lhs": 2,
  101. "no-nested-ternary": 0,
  102. "no-new": 2,
  103. "no-new-func": 0,
  104. "no-new-object": 2,
  105. "no-new-require": 2,
  106. "no-new-wrappers": 2,
  107. "no-obj-calls": 2,
  108. "no-octal": 2,
  109. "no-octal-escape": 2,
  110. "no-param-reassign": 0,
  111. "no-path-concat": 0,
  112. "no-process-env": 0,
  113. "no-process-exit": 0,
  114. "no-proto": 0,
  115. "no-redeclare": 2,
  116. "no-regex-spaces": 2,
  117. "no-restricted-modules": 0,
  118. "no-return-assign": 2,
  119. "no-script-url": 0,
  120. "no-self-compare": 2,
  121. "no-sequences": 2,
  122. "no-shadow": 0,
  123. "no-shadow-restricted-names": 2,
  124. "no-spaced-func": 2,
  125. "no-sparse-arrays": 2,
  126. "no-sync": 0,
  127. "no-ternary": 0,
  128. "no-this-before-super": 2,
  129. "no-throw-literal": 2,
  130. "no-trailing-spaces": 2,
  131. "no-undef": 2,
  132. "no-undef-init": 2,
  133. "no-undefined": 0,
  134. "no-underscore-dangle": 0,
  135. "no-unexpected-multiline": 2,
  136. "no-unneeded-ternary": 2,
  137. "no-unreachable": 2,
  138. "no-unused-expressions": 0,
  139. "no-unused-vars": [2, { "vars": "all", "args": "none" }],
  140. "no-use-before-define": 0,
  141. "no-var": 0,
  142. "no-void": 0,
  143. "no-warning-comments": 0,
  144. "no-with": 2,
  145. "object-curly-spacing": 0,
  146. "object-shorthand": 0,
  147. "one-var": [2, { "initialized": "never" }],
  148. "operator-assignment": 0,
  149. "operator-linebreak": [2, "after", { "overrides": { "?": "before", ":": "before" } }],
  150. "padded-blocks": 0,
  151. "prefer-const": 0,
  152. "quote-props": 0,
  153. "quotes": [2, "single", "avoid-escape"],
  154. "radix": 2,
  155. "semi": [2, "never"],
  156. "semi-spacing": 0,
  157. "sort-vars": 0,
  158. "space-after-keywords": [2, "always"],
  159. "space-before-blocks": [2, "always"],
  160. "space-before-function-paren": [2, "always"],
  161. "space-in-parens": [2, "never"],
  162. "space-infix-ops": 2,
  163. "space-return-throw-case": 2,
  164. "space-unary-ops": [2, { "words": true, "nonwords": false }],
  165. "spaced-comment": [2, "always", { "markers": ["global", "globals", "eslint", "eslint-disable", "*package", "!"] }],
  166. "strict": 0,
  167. "use-isnan": 2,
  168. "valid-jsdoc": 0,
  169. "valid-typeof": 2,
  170. "vars-on-top": 0,
  171. "wrap-iife": [2, "any"],
  172. "wrap-regex": 0,
  173. "yoda": [2, "never"]
  174. }
  175. }