.eslintrc.cjs 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. module.exports = {
  2. root: true,
  3. env: {
  4. node: true,
  5. jest: true,
  6. browser: true,
  7. },
  8. parser: "@typescript-eslint/parser",
  9. parserOptions: {
  10. sourceType: "module",
  11. requireConfigFile: false,
  12. ecmaVersion: 2021,
  13. },
  14. plugins: ["prettier"],
  15. extends: [
  16. "prettier/prettier",
  17. "eslint:recommended",
  18. "plugin:prettier/recommended",
  19. "plugin:@typescript-eslint/eslint-recommended",
  20. "plugin:@typescript-eslint/recommended",
  21. ],
  22. rules: {
  23. semi: [2, "never"],
  24. "prettier/prettier": ["warn", { semi: false, trailingComma: "es5" }],
  25. "import/no-named-as-default": "off",
  26. "no-undef": "off",
  27. "@typescript-eslint/no-explicit-any": "off",
  28. "@typescript-eslint/no-non-null-assertion": "off",
  29. "@typescript-eslint/no-unused-vars": [
  30. "error",
  31. {
  32. args: "all",
  33. argsIgnorePattern: "^_",
  34. caughtErrors: "all",
  35. caughtErrorsIgnorePattern: "^_",
  36. destructuredArrayIgnorePattern: "^_",
  37. varsIgnorePattern: "^_",
  38. ignoreRestSiblings: true,
  39. },
  40. ],
  41. },
  42. }