rollup.config.js 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. import { terser } from "rollup-plugin-terser";
  2. export default [{
  3. input: ["lib/single-file/index.js"],
  4. output: [{
  5. file: "dist/single-file.js",
  6. format: "umd",
  7. name: "singlefile",
  8. plugins: [terser()]
  9. }]
  10. }, {
  11. input: ["lib/single-file/single-file-frames.js"],
  12. output: [{
  13. file: "dist/single-file-frames.js",
  14. format: "umd",
  15. name: "singlefile",
  16. plugins: [terser()]
  17. }]
  18. }, {
  19. input: ["lib/single-file/single-file-bootstrap.js"],
  20. output: [{
  21. file: "dist/single-file-bootstrap.js",
  22. format: "umd",
  23. name: "singlefileBootstrap",
  24. plugins: [terser()]
  25. }]
  26. }, {
  27. input: ["common/ui/content/content-infobar.js"],
  28. output: [{
  29. file: "dist/infobar.js",
  30. format: "umd",
  31. name: "infobar",
  32. plugins: [terser()]
  33. }]
  34. }, {
  35. input: ["extension/core/content/content-bootstrap.js"],
  36. output: [{
  37. file: "dist/extension-bootstrap.js",
  38. format: "iife",
  39. plugins: [terser()]
  40. }]
  41. }, {
  42. input: ["extension/core/content/content-frames.js"],
  43. output: [{
  44. file: "dist/extension-frames.js",
  45. format: "iife",
  46. plugins: [terser()]
  47. }]
  48. }, {
  49. input: ["extension/core/content/content.js"],
  50. output: [{
  51. file: "dist/extension.js",
  52. format: "iife",
  53. plugins: [terser()]
  54. }]
  55. }, {
  56. input: ["lib/single-file/processors/hooks/content/content-hooks-web.js"],
  57. output: [{
  58. file: "dist/web/hooks/hooks-web.js",
  59. format: "iife",
  60. plugins: [terser()]
  61. }]
  62. }, {
  63. input: ["lib/single-file/processors/hooks/content/content-hooks-frames-web.js"],
  64. output: [{
  65. file: "dist/web/hooks/hooks-frames-web.js",
  66. format: "iife",
  67. plugins: [terser()]
  68. }]
  69. }, {
  70. input: ["common/ui/content/content-infobar-web.js"],
  71. output: [{
  72. file: "dist/web/infobar-web.js",
  73. format: "iife",
  74. plugins: [terser()]
  75. }]
  76. }, {
  77. input: ["extension/ui/content/content-ui-editor-init-web.js"],
  78. output: [{
  79. file: "dist/web/editor/editor-init-web.js",
  80. format: "iife",
  81. plugins: [terser()]
  82. }]
  83. }, {
  84. input: ["extension/ui/content/content-ui-editor-web.js"],
  85. output: [{
  86. file: "dist/web/editor/editor-web.js",
  87. format: "iife",
  88. plugins: [terser()]
  89. }]
  90. }, {
  91. input: ["extension/lib/single-file/browser-polyfill/chrome-browser-polyfill.js"],
  92. output: [{
  93. file: "dist/chrome-browser-polyfill.js",
  94. format: "iife",
  95. plugins: [terser()]
  96. }]
  97. }];