theseus/bundled-addons/aegis
Local Dev 65b4ac5ad3 perf(aegis): 251 KB off every panel open — jsQR loads when it is wanted
panel.html loaded lib/jsqr.js synchronously: 257 KB and 10,105 lines of
vendored decoder parsed on every panel open, so on every hide/show, for a
feature most sessions never touch. It is now fetched the first time someone
imports a QR image, with concurrent callers sharing one load and a failed
load retryable rather than cached as a permanent rejection.

qr.js and panel.js get `defer`, so the browser can paint the (already dark)
document before executing 300 KB of panel.js. Order is preserved, so qr.js
is still defined before panel.js runs.

Parsed on open: 650 KB -> 399 KB.

This shortens the blank window but does not remove it. The white box itself
is Theseus-side: the sidebar panel's view is built as

  new WebContentsView({ webPreferences: { preload: "sidebar-preload.js" } })

with no backgroundColor, and Electron defaults a view's background to white —
so white shows from view-attach until the page paints. Every other view in
the app passes a colour, and registerSidebarPanel takes only
{id, title, icon, page}, so an add-on cannot declare one. Not fixed here:
main.js belongs to the Theseus work in flight.
2026-10-03 16:39:45 +02:00
..
lib perf(aegis): history was 473 round trips in series, and persisted all of them 2026-10-03 16:12:53 +02:00
addon.json perf(aegis): 251 KB off every panel open — jsQR loads when it is wanted 2026-10-03 16:39:45 +02:00
electrum-servers.json Ship Theseus 0.3.28 5d15508b (Aegis update card + DevTools in tab sidebar + real favicons) 2026-09-08 18:17:25 +02:00
index.js feat(aegis): recover DigiByte seeds from the 2018-19 mobile wallets 2026-10-03 14:13:25 +02:00
panel.html perf(aegis): 251 KB off every panel open — jsQR loads when it is wanted 2026-10-03 16:39:45 +02:00
panel.js perf(aegis): 251 KB off every panel open — jsQR loads when it is wanted 2026-10-03 16:39:45 +02:00
qr.js Ship Theseus 0.3.28 5d15508b (Aegis update card + DevTools in tab sidebar + real favicons) 2026-09-08 18:17:25 +02:00
wallet-inject.js feat(aegis): the BCH bridge works on any site, not just .x 2026-10-03 09:45:01 +02:00