.eslintrc.js 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. module.exports = {
  2. root: true,
  3. env: {
  4. node: true
  5. },
  6. extends: [
  7. "plugin:vue/essential",
  8. // '@vue/standard',
  9. "eslint:recommended",
  10. "@vue/typescript/recommended"
  11. ],
  12. parserOptions: {
  13. ecmaVersion: 2020
  14. },
  15. rules: {
  16. "@typescript-eslint/ban-types": "off",
  17. "@typescript-eslint/ban-ts-comment": "off",
  18. "@typescript-eslint/explicit-module-boundary-types": "off",
  19. "@typescript-eslint/member-delimiter-style": [
  20. "error",
  21. {
  22. multiline: {
  23. delimiter: "none"
  24. },
  25. singleline: {
  26. delimiter: "comma"
  27. }
  28. }
  29. ],
  30. "@typescript-eslint/no-explicit-any": "off",
  31. "@typescript-eslint/no-var-requires": "off",
  32. "no-console": process.env.NODE_ENV === "production" ? "error" : "off",
  33. "no-debugger": process.env.NODE_ENV === "production" ? "error" : "off",
  34. "space-before-function-paren": [
  35. "error",
  36. { anonymous: "always", named: "never", asyncArrow: "always" }
  37. ],
  38. "vue/array-bracket-spacing": "error",
  39. "vue/arrow-spacing": "error",
  40. "vue/block-spacing": "error",
  41. "vue/brace-style": "error",
  42. "vue/camelcase": "error",
  43. "vue/comma-dangle": "error",
  44. "vue/component-name-in-template-casing": ["error", "kebab-case"],
  45. "vue/eqeqeq": ["off"],
  46. "vue/key-spacing": "error",
  47. "vue/match-component-file-name": "error",
  48. "vue/object-curly-spacing": ["error", "always"]
  49. },
  50. overrides: [
  51. {
  52. files: [
  53. "**/__tests__/*.{j,t}s?(x)",
  54. "**/tests/unit/**/*.spec.{j,t}s?(x)"
  55. ],
  56. env: {
  57. jest: true
  58. }
  59. }
  60. ]
  61. };