You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

app.js 1.7KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. /* Jitsi Meet app main entrypoint. */
  2. // Polyfill Promise.withReolvers.
  3. // FIXME(saghul) webpack + core-js v3 should polyfill this.
  4. import 'promise.withresolvers/auto';
  5. // Re-export jQuery
  6. // FIXME: Remove this requirement from torture tests.
  7. import $ from 'jquery';
  8. window.$ = window.jQuery = $;
  9. import '@matrix-org/olm';
  10. import 'focus-visible';
  11. // We need to setup the jitsi-local-storage as early as possible so that we can start using it.
  12. // NOTE: If jitsi-local-storage is used before the initial setup is performed this will break the use case when we use
  13. // the local storage from the parent page when the localStorage is disabled. Also the setup is relying that
  14. // window.location is not changed and still has all URL parameters.
  15. import './react/features/base/jitsi-local-storage/setup';
  16. import conference from './conference';
  17. import API from './modules/API';
  18. import UI from './modules/UI/UI';
  19. import translation from './modules/translation/translation';
  20. // Initialize Olm as early as possible.
  21. if (window.Olm) {
  22. window.Olm.init().catch(e => {
  23. console.error('Failed to initialize Olm, E2EE will be disabled', e);
  24. delete window.Olm;
  25. });
  26. }
  27. window.APP = {
  28. API,
  29. conference,
  30. translation,
  31. UI
  32. };
  33. // TODO The execution of the mobile app starts from react/index.native.js.
  34. // Similarly, the execution of the Web app should start from react/index.web.js
  35. // for the sake of consistency and ease of understanding. Temporarily though
  36. // because we are at the beginning of introducing React into the Web app, allow
  37. // the execution of the Web app to start from app.js in order to reduce the
  38. // complexity of the beginning step.
  39. import './react';