.eslintrc.json 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. {
  2. "root": true,
  3. "extends": [
  4. "plugin:import/errors",
  5. "plugin:import/warnings",
  6. "plugin:unicorn/recommended",
  7. "xo",
  8. "xo/browser"
  9. ],
  10. "rules": {
  11. "capitalized-comments": "off",
  12. "indent": [
  13. "error",
  14. 2,
  15. {
  16. "MemberExpression": "off",
  17. "SwitchCase": 1
  18. }
  19. ],
  20. "max-params": [
  21. "warn",
  22. 5
  23. ],
  24. "multiline-ternary": [
  25. "error",
  26. "always-multiline"
  27. ],
  28. "new-cap": [
  29. "error",
  30. {
  31. "properties": false
  32. }
  33. ],
  34. "no-eq-null": "off",
  35. "no-negated-condition": "off",
  36. "no-console": "error",
  37. "object-curly-spacing": [
  38. "error",
  39. "always"
  40. ],
  41. "prefer-object-spread": "off",
  42. "semi": [
  43. "error",
  44. "never"
  45. ],
  46. "unicorn/filename-case": "off",
  47. "unicorn/no-null": "off",
  48. "unicorn/prevent-abbreviations": "off"
  49. },
  50. "overrides": [
  51. {
  52. "files": ["*.ts", "*.tsx"],
  53. "extends": [
  54. "plugin:import/typescript",
  55. "xo-typescript"
  56. ],
  57. "rules": {
  58. "@typescript-eslint/indent": [
  59. "error",
  60. 2,
  61. {
  62. "MemberExpression": "off",
  63. "SwitchCase": 1
  64. }
  65. ],
  66. "@typescript-eslint/semi": [
  67. "error",
  68. "never"
  69. ]
  70. }
  71. }
  72. ]
  73. }