.eslintrc 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. {
  2. "parserOptions": {
  3. "sourceType": "module"
  4. },
  5. "env": {
  6. "node": true,
  7. "browser": true
  8. },
  9. "extends": "eslint:recommended",
  10. "rules": {
  11. "no-alert": 2,
  12. "no-array-constructor": 2,
  13. "no-caller": 2,
  14. "no-catch-shadow": 2,
  15. "no-eval": 2,
  16. "no-extend-native": 2,
  17. "no-extra-bind": 2,
  18. "no-implied-eval": 2,
  19. "no-iterator": 2,
  20. "no-label-var": 2,
  21. "no-labels": 2,
  22. "no-lone-blocks": 2,
  23. "no-loop-func": 2,
  24. "no-multi-spaces": 2,
  25. "no-multi-str": 2,
  26. "no-native-reassign": 2,
  27. "no-new": 2,
  28. "no-new-func": 2,
  29. "no-new-object": 2,
  30. "no-new-wrappers": 2,
  31. "no-octal-escape": 2,
  32. "no-process-exit": 2,
  33. "no-proto": 2,
  34. "no-return-assign": 2,
  35. "no-script-url": 2,
  36. "no-sequences": 2,
  37. "no-shadow": 2,
  38. "no-shadow-restricted-names": 2,
  39. "no-spaced-func": 2,
  40. "no-trailing-spaces": 2,
  41. "no-undef-init": 2,
  42. "no-underscore-dangle": 0,
  43. "no-unused-expressions": 2,
  44. "no-use-before-define": 2,
  45. "no-with": 2,
  46. "camelcase": 1,
  47. "comma-spacing": 2,
  48. "consistent-return": 2,
  49. "curly": [ 2, "all" ],
  50. "dot-notation": [ 2, { "allowKeywords": true } ],
  51. "eol-last": 2,
  52. "no-extra-parens": [ 2, "functions" ],
  53. "eqeqeq": 2,
  54. "keyword-spacing": [ 2, { "before": true, "after": true } ],
  55. "key-spacing": [ 2, { "beforeColon": false, "afterColon": true } ],
  56. "new-cap": 2,
  57. "new-parens": 2,
  58. "quotes": [ 2, "single" ],
  59. "semi": 2,
  60. "semi-spacing": [ 2, { "before": false, "after": true } ],
  61. "space-infix-ops": 2,
  62. "space-unary-ops": [ 2, { "words": true, "nonwords": false } ],
  63. "strict": [ 2, "global" ],
  64. "yoda": [ 2, "never" ]
  65. },
  66. "overrides": [
  67. {
  68. "files": [ "*.js", "test/*.js" ],
  69. "excludedFiles": "examples/*.js"
  70. }
  71. ]
  72. }