.babelrc 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. {
  2. "plugins": [
  3. "@babel/plugin-proposal-object-rest-spread",
  4. "@babel/plugin-syntax-dynamic-import",
  5. "@babel/plugin-syntax-import-meta",
  6. "@babel/plugin-proposal-json-strings",
  7. ["@babel/plugin-proposal-decorators", { "legacy": true }],
  8. ["@babel/plugin-proposal-class-properties", { "loose": true }],
  9. "@babel/plugin-proposal-function-sent",
  10. "@babel/plugin-proposal-export-namespace-from",
  11. "@babel/plugin-proposal-numeric-separator",
  12. "@babel/plugin-proposal-throw-expressions",
  13. "@babel/plugin-proposal-export-default-from",
  14. "@babel/plugin-proposal-logical-assignment-operators",
  15. "@babel/plugin-proposal-optional-chaining",
  16. [
  17. "@babel/plugin-proposal-pipeline-operator",
  18. {
  19. "proposal": "minimal"
  20. }
  21. ],
  22. "@babel/plugin-proposal-nullish-coalescing-operator",
  23. "@babel/plugin-proposal-do-expressions",
  24. "@babel/plugin-proposal-function-bind"
  25. ],
  26. "presets": [
  27. "@babel/preset-react"
  28. ],
  29. "env": {
  30. "production": {
  31. "presets": [
  32. [
  33. "@babel/preset-env",
  34. {
  35. "targets": {
  36. "browsers": [
  37. "last 2 versions",
  38. "ie >= 10"
  39. ]
  40. }
  41. }
  42. ]
  43. ],
  44. "plugins": [
  45. ]
  46. },
  47. "development": {
  48. "sourceMaps": "inline"
  49. },
  50. "test": {
  51. "presets": [
  52. [
  53. "@babel/preset-env",
  54. {
  55. "targets": {
  56. "node": "8"
  57. }
  58. }
  59. ]
  60. ]
  61. }
  62. }
  63. }