.eslintrc.js 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. module.exports = {
  2. parser: 'vue-eslint-parser',
  3. parserOptions: {
  4. parser: '@typescript-eslint/parser',
  5. ecmaVersion: 2020,
  6. sourceType: 'module',
  7. ecmaFeatures: {
  8. jsx: true,
  9. jsx: true,
  10. },
  11. },
  12. extends: [
  13. 'plugin:vue/vue3-recommended',
  14. 'plugin:@typescript-eslint/recommended',
  15. 'prettier/@typescript-eslint',
  16. 'plugin:prettier/recommended',
  17. ],
  18. rules: {
  19. '@typescript-eslint/ban-ts-ignore': 'off',
  20. '@typescript-eslint/explicit-function-return-type': 'off',
  21. '@typescript-eslint/no-explicit-any': 'off',
  22. '@typescript-eslint/no-var-requires': 'off',
  23. '@typescript-eslint/no-empty-function': 'off',
  24. 'vue/custom-event-name-casing': 'off',
  25. 'no-use-before-define': 'off',
  26. // 'no-use-before-define': [
  27. // 'error',
  28. // {
  29. // functions: false,
  30. // classes: true,
  31. // },
  32. // ],
  33. '@typescript-eslint/no-use-before-define': 'off',
  34. // '@typescript-eslint/no-use-before-define': [
  35. // 'error',
  36. // {
  37. // functions: false,
  38. // classes: true,
  39. // },
  40. // ],
  41. '@typescript-eslint/ban-ts-comment': 'off',
  42. '@typescript-eslint/ban-types': 'off',
  43. '@typescript-eslint/no-non-null-assertion': 'off',
  44. '@typescript-eslint/explicit-module-boundary-types': 'off',
  45. '@typescript-eslint/no-unused-vars': [
  46. 'error',
  47. {
  48. argsIgnorePattern: '^h$',
  49. varsIgnorePattern: '^h$',
  50. },
  51. ],
  52. 'no-unused-vars': [
  53. 'error',
  54. {
  55. argsIgnorePattern: '^h$',
  56. varsIgnorePattern: '^h$',
  57. },
  58. ],
  59. 'space-before-function-paren': 'off',
  60. },
  61. };