main.js 646 B

1234567891011121314151617181920212223242526272829303132
  1. const Uppy = require('uppy/lib/core')
  2. const Dashboard = require('uppy/lib/plugins/Dashboard')
  3. const GoldenRetriever = require('uppy/lib/plugins/GoldenRetriever')
  4. // Initialise two Uppy instances with the GoldenRetriever plugin,
  5. // but with different `id`s.
  6. const a = Uppy({
  7. id: 'a',
  8. debug: true
  9. })
  10. .use(Dashboard, {
  11. target: '#a',
  12. inline: true,
  13. width: 400
  14. })
  15. .use(GoldenRetriever, { serviceWorker: false })
  16. .run()
  17. const b = Uppy({
  18. id: 'b',
  19. debug: true
  20. })
  21. .use(Dashboard, {
  22. target: '#b',
  23. inline: true,
  24. width: 400
  25. })
  26. .use(GoldenRetriever, { serviceWorker: false })
  27. .run()
  28. window.a = a
  29. window.b = b