element-hq / element-call

Group calls powered by Matrix
https://call.element.io
GNU Affero General Public License v3.0
591 stars 92 forks source link

Lazy load matrix-js-sdk when running as SPA #2785

Closed hughns closed 1 week ago

hughns commented 1 week ago

This refactors the code that loads the js-sdk which allows vite to split the bundle.

If EC finds that it has the widget API then it doesn't bother to load the rest of the js-sdk stuff (including rust-crypto). 🚀