2
0

.eslintrc 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. {
  2. "parser": "@typescript-eslint/parser",
  3. "plugins": [
  4. "@typescript-eslint"
  5. ],
  6. "extends": [
  7. "wagtail",
  8. "plugin:@typescript-eslint/recommended"
  9. ],
  10. "env": {
  11. "jest": true
  12. },
  13. "settings": {
  14. "import/resolver": {
  15. "webpack": {
  16. "config": "client/webpack.config.js"
  17. }
  18. }
  19. },
  20. "rules": {
  21. "no-underscore-dangle": ["error", { "allow": ["__REDUX_DEVTOOLS_EXTENSION__"] }],
  22. // note you must disable the base rule as it can report incorrect errors
  23. "no-use-before-define": "off",
  24. "@typescript-eslint/no-use-before-define": ["error"],
  25. "@typescript-eslint/explicit-module-boundary-types": "off",
  26. "@typescript-eslint/explicit-member-accessibility": "off",
  27. "@typescript-eslint/explicit-function-return-type": "off",
  28. "@typescript-eslint/no-explicit-any": "off"
  29. },
  30. "overrides": [
  31. {
  32. // Rules we don’t want to enforce for test and tooling code.
  33. "files": ["*.test.ts", "*.test.tsx", "*.test.js", "webpack.config.js"],
  34. "rules": {
  35. "@typescript-eslint/no-empty-function": "off",
  36. "@typescript-eslint/no-var-requires": "off"
  37. }
  38. }
  39. ]
  40. }