feat: fix types and add type checking plus lazybundle on launch andddd dev flag

This commit is contained in:
Brooklyn Nicholson 2026-04-11 14:42:28 -05:00
parent 5e5e65f6d5
commit 32302c37dd
34 changed files with 1807 additions and 977 deletions

View file

@ -63,14 +63,11 @@ export function renderToScreen(el: ReactElement, width: number): { screen: Scree
stylePool = new StylePool()
charPool = new CharPool()
hyperlinkPool = new HyperlinkPool()
// @ts-expect-error react-reconciler 0.33 takes 10 args; @types says 11
container = reconciler.createContainer(root, LegacyRoot, null, false, null, 'search-render', noop, noop, noop, noop)
}
const t0 = performance.now()
// @ts-expect-error updateContainerSync exists but not in @types
reconciler.updateContainerSync(el, container, null, noop)
// @ts-expect-error flushSyncWork exists but not in @types
reconciler.flushSyncWork()
const t1 = performance.now()
@ -105,9 +102,7 @@ export function renderToScreen(el: ReactElement, width: number): { screen: Scree
const t3 = performance.now()
// Unmount so next call gets a fresh tree. Leaves root/container/pools.
// @ts-expect-error updateContainerSync exists but not in @types
reconciler.updateContainerSync(null, container, null, noop)
// @ts-expect-error flushSyncWork exists but not in @types
reconciler.flushSyncWork()
timing.reconcile += t1 - t0