.eslintrc.js 1003 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. /*
  2. * @Author: wjc
  3. * @Date: 2023-05-07 12:04:34
  4. * @LastEditors: ChenYaJin
  5. * @LastEditTime: 2023-08-02 15:49:29
  6. * @Description:
  7. */
  8. module.exports = {
  9. root: true,
  10. env: {
  11. browser: true,
  12. node: true,
  13. },
  14. extends: [
  15. 'plugin:vue/vue3-recommended',
  16. 'plugin:@typescript-eslint/recommended',
  17. 'prettier',
  18. 'plugin:prettier/recommended',
  19. ],
  20. parser: 'vue-eslint-parser',
  21. parserOptions: {
  22. ecmaVersion: 2020,
  23. // 指定eslint解析器
  24. parser: '@typescript-eslint/parser',
  25. // 允许使用 import
  26. sourceType: 'module',
  27. // 允许解析 jsx
  28. ecmaFeatures: {
  29. jsx: true,
  30. },
  31. },
  32. plugins: ['vue', '@typescript-eslint'],
  33. rules: {
  34. 'vue/valid-template-root': [0],
  35. 'vue/no-reserved-component-names': 'off',
  36. 'vue/multi-word-component-names': 'off',
  37. '@typescript-eslint/no-explicit-any': 'off',
  38. '@typescript-eslint/ban-ts-ignore': 'off',
  39. // 'no-unused-vars': 'off',
  40. // '@typescript-eslint/no-unused-vars': 'error',
  41. },
  42. }