.eslintrc.js 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. module.exports = {
  2. root: true,
  3. env: {
  4. node: true
  5. },
  6. 'extends': [
  7. 'plugin:vue/strongly-recommended',
  8. '@vue/standard'
  9. ],
  10. rules: {
  11. 'no-console': 'off',
  12. 'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
  13. 'generator-star-spacing': 'off',
  14. 'no-mixed-operators': 0,
  15. 'space-before-function-paren':0,
  16. 'vue/max-attributes-per-line': [
  17. 2,
  18. {
  19. 'singleline': 5,
  20. 'multiline': {
  21. 'max': 1,
  22. 'allowFirstLine': false
  23. }
  24. }
  25. ],
  26. 'vue/attribute-hyphenation': 0,
  27. 'vue/html-self-closing': 0,
  28. 'vue/component-name-in-template-casing': 0,
  29. 'vue/html-closing-bracket-spacing': 0,
  30. 'vue/singleline-html-element-content-newline': 0,
  31. 'vue/no-unused-components': 0,
  32. 'vue/multiline-html-element-content-newline': 0,
  33. 'vue/no-use-v-if-with-v-for': 0,
  34. 'vue/html-closing-bracket-newline': 0,
  35. 'vue/no-parsing-error': 0,
  36. 'no-tabs': 0,
  37. 'quotes': [
  38. 2,
  39. 'single',
  40. {
  41. 'avoidEscape': true,
  42. 'allowTemplateLiterals': true
  43. }
  44. ],
  45. 'semi': [
  46. 2,
  47. 'never',
  48. {
  49. 'beforeStatementContinuationChars': 'never'
  50. }
  51. ],
  52. 'no-delete-var': 2,
  53. 'prefer-const': [
  54. 2,
  55. {
  56. 'ignoreReadBeforeAssign': false
  57. }
  58. ],
  59. 'template-curly-spacing': 'off',
  60. 'indent': 'off'
  61. },
  62. parserOptions: {
  63. parser: 'babel-eslint'
  64. },
  65. overrides: [
  66. {
  67. files: [
  68. '**/__tests__/*.{j,t}s?(x)',
  69. '**/tests/unit/**/*.spec.{j,t}s?(x)'
  70. ],
  71. env: {
  72. jest: true
  73. }
  74. }
  75. ]
  76. }