.eslintrc.js 911 B

1234567891011121314151617181920212223242526272829303132
  1. module.exports = {
  2. parser: 'babel-eslint',
  3. extends: ['airbnb', 'prettier', 'plugin:compat/recommended'],
  4. env: {
  5. browser: true,
  6. node: true,
  7. es6: true,
  8. mocha: true,
  9. jest: true,
  10. jasmine: true,
  11. },
  12. globals: {
  13. APP_TYPE: true,
  14. },
  15. rules: {
  16. 'react/jsx-filename-extension': [1, { extensions: ['.js'] }],
  17. 'react/jsx-wrap-multilines': 0,
  18. 'react/prop-types': 0,
  19. 'react/forbid-prop-types': 0,
  20. 'react/jsx-one-expression-per-line': 0,
  21. 'import/no-unresolved': [2, { ignore: ['^@/', '^umi/'] }],
  22. 'import/no-extraneous-dependencies': [2, { optionalDependencies: true }],
  23. 'jsx-a11y/no-noninteractive-element-interactions': 0,
  24. 'jsx-a11y/click-events-have-key-events': 0,
  25. 'jsx-a11y/no-static-element-interactions': 0,
  26. 'jsx-a11y/anchor-is-valid': 0,
  27. 'linebreak-style': 0,
  28. },
  29. settings: {
  30. polyfills: ['fetch', 'promises', 'url'],
  31. },
  32. };