.eslintrc.js 863 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. module.exports = {
  2. globals: {
  3. wx: true,
  4. },
  5. root: true,
  6. env: {
  7. node: true,
  8. },
  9. extends: [
  10. "plugin:vue/vue3-essential",
  11. "eslint:recommended",
  12. "@vue/typescript/recommended",
  13. "plugin:prettier/recommended",
  14. ],
  15. parserOptions: {
  16. ecmaVersion: 2020,
  17. },
  18. rules: {
  19. "no-console": process.env.NODE_ENV === "production" ? "warn" : "off",
  20. "no-debugger": process.env.NODE_ENV === "production" ? "warn" : "off",
  21. "@typescript-eslint/ban-ts-comment": "off",
  22. "@typescript-eslint/no-explicit-any": "off",
  23. "prettier/prettier": "off",
  24. "@typescript-eslint/no-var-requires": "off",
  25. "@typescript-eslint/no-namespace": "off",
  26. },
  27. overrides: [
  28. {
  29. files: [
  30. "**/__tests__/*.{j,t}s?(x)",
  31. "**/tests/unit/**/*.spec.{j,t}s?(x)",
  32. ],
  33. env: {
  34. jest: true,
  35. },
  36. },
  37. ],
  38. };