Skip to content

Run the website in Strong mode #2059

Closed
Closed

Description

@trueadm

Goal

website/ runs in Strong mode, along with the six workspace packages it imports. Only those six are in scope. The other bindings keep their current mode, and docs/strong-dependencies-plan.md still covers them.

Passing Strong checks and producing no element descriptors are separate results, so each has its own criteria. A .tsrx component that does return <div>Hello</div> passes strong: true, but it still emits createElementFromConfig.

Strong compliance. Done when:

  • Strong is on for the website's own modules and for its MDX documents, with no "use strong" exceptions.
  • octane analyze --strong-dependencies on the website lists no packages and no ReactCompat boundaries. Since fix(cli): follow a Strong dependency's own imports in Strong reports #2061, this check follows the imports of every Strong dependency module too, so an empty report covers the whole graph rather than only the first layer.
  • Once compiler.strongDependencies.require exists (step 3 of the Strong dependencies plan), the website turns it on with an empty allow list.

No descriptors. Done when:

  • The website's production client build contains no element-descriptor factories: createElement, createElementAt, createElementFromConfig or createHostElement.
  • That takes either a Strong rule against returned and value-position JSX in .tsrx, or a compiler change that lowers that JSX to templates. Which one is a design decision; see the open questions.

Both. Website e2e, each package's conformance and parity suites, and the examples that use these packages stay green.

What the website uses

Measured at d8e2d9f.

  • Findings: octane analyze --strong-preview over each package's shipped src/, without tests, upstream/ copies or .d.ts files. For the website, it ran over the 99 modules in website/src.
  • Imported from: the modules --strong-dependencies reported after every website module was marked "use strong" in a scratch worktree.
Package Used for Imported from Shipped files Modules with findings Findings
website 99 16 36
@octanejs/tanstack-router file routes, Link, hooks, root document 12 modules: Asset, Body, ClientOnly, Head, Html, Link, Outlet, Scripts, fileRoute, headContentUtils, hooks, route 63 19 37
@octanejs/tanstack-start StartClient, hydrateStart, createServerFn runtime/client/StartClient.js 155 7 34
@octanejs/three home page scene core/hooks.ts, web/Canvas.tsrx 24 2 16
@octanejs/mdx 19 docs pages compiled .mdx documents 4 2 2
@octanejs/devtools /devtools demo src/index.ts 9 1 1
@octanejs/tanstack-devtools /devtools demo not reported (see section 1) 2 1 4

Findings by code:

  • website:
    • 11 EXPLICIT_DEPENDENCIES
    • 5 EFFECT_STATE_UPDATE
    • 5 RENDER_REF_READ
    • 4 UNTRUSTED_HTML
    • 3 EFFECT_CHAIN
    • 2 RENDER_IMPURE_CALL
    • 2 RENDER_REF_WRITE
    • 1 each: ELEMENT_API, EVENT_HANDLER_LOCALITY, IMPURE_UPDATER, UNLINKED_PROP_STATE
  • tanstack-router:
    • 14 EXPLICIT_DEPENDENCIES
    • 12 ELEMENT_API
    • 3 UNTRUSTED_HTML
    • 2 RENDER_REF_READ
    • 2 RENDER_REF_WRITE
    • 2 SUPPRESSION_PROP
    • 1 COMPAT_IMPORT
    • 1 WRITE_ONLY_STATE
  • tanstack-start: 23 of its 34 findings are in GenericHydrate.tsrx, which the website does not import.
    • 9 EXPLICIT_DEPENDENCIES
    • 7 RENDER_REF_READ
    • 7 RENDER_REF_WRITE
    • 6 RENDER_AMBIENT_READ
    • 2 ELEMENT_API
    • 2 UNTRUSTED_HTML
    • 1 EFFECT_DATA_FETCH
  • three:
    • 15 in web/Canvas.tsrx: 10 render-time ref reads or writes, 3 explicit dependency arrays, 1 effect chain and 1 untracked effect.
    • 1 COMPAT_IMPORT in web/events.ts, which imports flushSync.
  • mdx: ELEMENT_API in MDXProvider, in index.ts and server.ts. That count doesn't include the documents; see section 3.
  • devtools: ELEMENT_API in index.ts.
  • tanstack-devtools: 2 MAP_JSX and 2 EXPLICIT_DEPENDENCIES.

Why the scope stays small:

  • Only plain createElement. Every element-API use in these packages is plain createElement, in 18 files. None uses cloneElement, isValidElement, Children or descriptorChildren, so nothing falls into the plan's "redesign" group.
  • No .tsx files. None of the six packages ships a .tsx file, and website/src has none, so the .tsx ban (feat(compiler): reject Strong .tsx and .jsx modules #2057) needs no conversions.
  • No React. The website has no react dependency and no live ReactCompat boundary.
  • @octanejs/visx is unused. It is a website dependency, but nothing imports it any more. Drop it from website/package.json, and drop its optimizeDeps entries from vite.config.ts.
  • Build-time entries are unaffected. @octanejs/tanstack-start/plugin/vite, @octanejs/three/config and @octanejs/mdx/vite don't render anything.
  • The playground is out of scope. It compiles visitors' code at runtime, in that code's own mode.

Plan

1. Tooling and enforcement

  • Report fixes. Three --strong-dependencies gaps found while measuring are fixed or in review:
  • Same-package checks. With the declaration's directory form, enforcement must also check imports from Strong modules into compatibility modules within the same package.
  • Pick one place to turn Strong on. octane analyze could not read Strong from the website. Given a temporary octane.config.ts, it said the file "could not be evaluated because @octanejs/app-core is not installed". The website's Octane options live in tanstackStart({ octane: … }) in vite.config.ts. Both the build and octane analyze must read the chosen place.
  • Implement the plan's steps 2 and 3. That is the package declaration (octane.strong) and the application requirement (compiler.strongDependencies.require). The router and start packages need the declaration's directory form, which the plan leaves open (sections 4 and 5).

2. Website code: 36 findings in 16 modules

In progress in a separate PR, together with section 7, as announced in the investigation comment below. That PR also adds a shared Strong configuration for the website. This is mechanical work: put "use strong" on each file as it is fixed, until the policy covers the whole site.

  • Explicit dependency arrays: omit or reconcile all 11.
  • Render-time ref reads and writes in CoreApiDemo, OnThisPage, PortalEventDemo and LynxPreview: move them to state, useLazyRef or useLayoutSnapshot.
  • State updates in effect setup, and effect chains, in OnThisPage, PortalEventDemo, ThemeToggle, Go and Playground: derive the value, or use useLinkedState or useLayoutSnapshot.
  • dangerouslySetInnerHTML in Header, DeviceScan, Go and __root: call trustHTML() at the trusted source, such as the Shiki output or the inline theme script.
  • Remaining one-offs:
    • Date.now() and Math.random() during render in DevtoolsDemo
    • the createElement in SiteHeadContent
    • the updater in DocsSearch
    • the prop-derived state in BenchmarkExplorer
    • the handler placement in CoreApiDemo

3. @octanejs/mdx: compile documents as Strong templates

This is the largest item. Every docs page renders through the generic descriptor renderer, and none is Strong.

octaneMdx() compiles a document's JSX the way .tsx compiles: returned JSX is lowered to element descriptors, and it never passes strong.

Descriptor calls per page (createElementFromConfig and createHostElement):

Document Default options Website's Shiki options
quick-start.mdx 83 365
core-apis.mdx 683 3,113

Convert both generated functions. Converting only _createMdxContent leaves descriptor creation in MDXContent.

A naive conversion is much larger. The investigation comment below converted both functions in a scratch build. That removed the descriptor factories, but every _components.* tag became a generic component slot. These are isolated, independently minified modules, not production bundles or runtime benchmarks:

Website document Current module, gzip Template module, gzip
Quick Start 8,617 B 28,457 B
Core APIs 59,611 B 201,662 B

Proposed: a build-time override list. The growth comes from routing every markdown tag through _components.*, including Shiki's thousands of highlighting spans. The website overrides only table and pre (docComponents in website/src/pages/doc-page/DocPage.tsrx).

  • Add an octaneMdx() option that names the overridable tags at build time. Every other tag compiles to a static host template, and only the listed tags stay component tags.
  • The default keeps every tag overridable, for MDX parity.

Measure it the same way before treating the conversion as an improvement.

What the conversion must keep:

  • The precedence between MDXProvider overrides and components prop overrides.
  • Matching server and client output, because hydration depends on it.
  • HMR and source maps.

Remaining steps:

  • Strong: compile documents under the application's Strong policy.
  • MDXProvider: rewrite it as .tsrx in index.ts and server.ts. Each has one createElement.

4. @octanejs/tanstack-router

The website uses:

  • Routing: Link, createFileRoute, createRootRoute, Outlet and notFound.
  • Hooks: the read hooks, useHydrated and useTags.
  • Document components: Html, Head, Body, Scripts, Asset and HeadContent.
  • shellComponent: __root.tsrx sets shellComponent: RootDocument.

#2054 added @octanejs/tanstack-router/compiled, an entry that renders compiled route bodies only and so avoids the descriptor renderer. It has no Link or document components yet, owns a separate pair of contexts, and rejects shellComponent, Wrap and InnerWrap.

Decision needed:

  • A (recommended): extend /compiled to cover the website's surface: Link, the document components, shellComponent, and file routes with route-bound hooks. Then move the website onto it.
    • This keeps the compiled entry's bundle boundary. Share the existing hook factories rather than copying them, and keep Start and Body in charge of hydration.
    • The ordinary entry stays the compatibility path for returned JSX, host strings and wrappers.
    • The package then ships a Strong entry next to a compatibility entry, so it needs the directory form of octane.strong, or per-module directives.
  • B: make the ordinary entry Strong by converting its 12 createElement modules, and declare the whole package Strong.
    • Route components chosen at runtime would still reach childSlot, unless they render as checked compiled boundaries. Avoiding that is why /compiled exists.

Either way:

  • flushSync: link.ts calls flushSync at line 291 for its transition flag, and Strong bans it.
    • Its timing contract differs from three's renderer event flushing (section 6), so evaluate each separately. Together they don't automatically justify one new public synchronous API.
  • Inline scripts: ScriptOnce.tsrx and compiled/Matches.tsrx put suppressHydrationWarning on an inline <script>, and OCTANE_STRONG_SUPPRESSION_PROP rejects that.
    • ScriptOnce keeps the server's script and drops it after hydration. It does not remove itself; only the separate hydration-data scripts do.
    • Test both lifecycles with scripts actually executed in a browser before choosing between a script primitive and a narrow exemption.
    • trustHTML settles whether the HTML is trusted, not which code owns the script node.
  • Mechanical fixes:
    • 14 explicit dependency arrays
    • render-time refs in CatchBoundary and compiled/Matches
    • trustHTML for 3 raw-HTML sites
    • a write-only state in Transitioner

5. @octanejs/tanstack-start

6. @octanejs/three

  • Render-time refs: web/Canvas.tsrx copies props into refs during render for the imperative root, with 10 ref reads or writes. Move that work to a layout effect or useEffectEvent. Also fix its effect chain, its untracked effect and its 3 explicit dependency arrays.
  • flushSync: web/events.ts wraps discrete renderer events in flushSync at line 33. Strong bans it, and its timing contract differs from Link's (section 4).

7. Devtools packages

In progress together with section 2.

  • @octanejs/devtools/src/index.ts: rewrite its createElement as .tsrx.
  • @octanejs/tanstack-devtools/src/devtools.tsrx: turn its two JSX-returning .map() callbacks into @for, and fix its two explicit dependency arrays.

Order

  1. In progress:
  2. Small and independent: three, and mdx's MDXProvider.
  3. After the router decision (section 4): the router and start work together, because StartClient renders the chosen provider.
  4. MDX documents as templates (section 3): measure the override-list approach first, and coordinate the hydration side with Hydration: collapse the hydration engine back into the mount path (Ripple/Svelte-style cursor), 23 kB → ~5 kB gzip #2028.
  5. Last: package declarations for the six packages, then strong: true and require on the website.

Open questions

  • What replaces flushSync in Strong code? Link's transition flag and three's renderer event flushing have different timing contracts, so they may need different answers.
  • How should ScriptOnce's adopted server script hydrate without suppressHydrationWarning? And should the self-removing hydration-data scripts get the same answer?
  • What is the directory form of the octane.strong declaration? The router and start packages need it.
  • Should a Strong .tsrx module reject returned and value-position JSX, or should the compiler lower it to templates? The no-descriptors criteria need one or the other.

Related: docs/strong-dependencies-plan.md, #2028, #2054, #2055, #2056, #2057, #2060, #2061.

🤖 Generated with Claude Code

Activity

  1. domgan-oai commented on Oct 14, 2026

    @domgan-oai
    Contributor

    Investigated against d8e2d9fce8d1a12136e2b448830d90a628a3952f. The compiler reproduces all reported diagnostic totals: 36 website findings in 16 files, and 94 across the six packages. The website pass covered 98 implementation modules, excluding .d.ts files.

    A few findings affect the implementation plan:

    1. The two report fixes are covered by fix(cli): ignore text imports and follow renamed exports in Strong reports #2060. No duplicate fix is needed.

    2. An empty dependency report does not yet prove transitive Strong coverage. The current walker deliberately follows direct imports and re-exports, then skips dependency implementation imports. A synthetic graph using the actual compiler/report APIs — Strong app → Strong dependency → non-Strong implementation importing octane/react — returns empty packages and reactCompat arrays without visiting the final module. With directory declarations, enforcement also needs to check Strong-to-compat imports within the same package. See the walk.

    3. Strong compliance and descriptor-free output need separate acceptance criteria. On this compiler, export function A() { return <div>Hello</div>; } in a .tsrx file passes strong: true but emits createElementFromConfig. Passing Strong checks alone does not establish removal of descriptor reconciliation.

    4. MDX needs both generated functions converted, and naive conversion has a substantial code-size cost. Converting only _createMdxContent leaves descriptor creation in MDXContent. The default-options descriptor counts reproduce exactly (83 / 683). With the website's real Shiki options, the counts are 365 / 3,113. A scratch conversion of both functions removes those factories, but dynamic _components.* tags become hundreds/thousands of generic component slots.

      Website document Current independently minified module gzip Scratch template module gzip
      Quick Start 8,617 B 28,457 B
      Core APIs 59,611 B 201,662 B

      These are isolated compiler/minifier probes, not complete production bundles or runtime benchmarks. Strong disabled produces the same template raw size. Native-tag specialization needs investigation before treating this conversion as a performance improvement; preserve provider/prop override precedence, SSR/client agreement, HMR, and source maps.

    5. Router A remains the preferable direction when retaining the compiled entry's bundle boundary is a goal. Share the existing hook factories and preserve Start/Body hydration ownership. Link's transition flag and Three's renderer event flushing have different timing contracts; they do not automatically require the same new public synchronous API.

    6. The script lifecycles differ. ScriptOnce currently adopts the server script and drops it after hydration; it does not append document.currentScript.remove(). Separate hydration-data scripts really self-remove. Test both with executed browser scripts before selecting a primitive or suppression exemption. trustHTML addresses trust, not missing-node ownership.

    Starting the independent website/devtools portion in a separate PR: shared website Strong configuration, the website source conversions, and the two devtools packages. MDX, router/start/three, package declarations, and dependency enforcement remain follow-ups. Browser/hydration/parity suites were not run for the investigation; the implementation PR will carry its own validation.

    This comment was prepared and posted by a Codex agent.

  2. trueadm commented on Oct 14, 2026

    @trueadm
    CollaboratorAuthor

    Thanks. All six points are taken, and the issue body is updated:

    1. fix(cli): ignore text imports and follow renamed exports in Strong reports #2060 merged with both report fixes. It also covers a tagged-template case and a comment-backtick case that Bugbot found during review.
    2. The transitive gap is fixed in fix(cli): follow a Strong dependency's own imports in Strong reports #2061. A Strong module that the walk reaches in a dependency now gets the same check as the project's own Strong modules: its imports are followed through every Strong layer, down to the first module that isn't Strong. Its regression is your synthetic graph: Strong app → Strong Dialog.tsrx → non-Strong Backdrop.tsx that imports octane/react. Section 1 now also notes the check that the directory form will need between Strong and compatibility modules in the same package.
    3. Done criteria split. "Strong compliance" and "no descriptors" are now separate. The second is measured on the production client build. The question of rejecting or lowering returned and value-position JSX in Strong .tsrx is now an open question.
    4. MDX now covers both generated functions, the counts with the Shiki options (365 / 3,113), and your size probe. One addition: the website only overrides table and pre (docComponents in DocPage.tsrx). The section now proposes a build-time list of overridable tags for octaneMdx(). Every other tag, including Shiki's spans, would compile to a static host template. It also says to measure that with the same probe before treating the conversion as an improvement.
    5. Router A now notes sharing the hook factories and leaving hydration to Start and Body. The flushSync notes treat Link's transition flag and three's event flushing as separate timing contracts.
    6. The ScriptOnce description is corrected. It keeps the server's script and drops it after hydration. The open question now covers both lifecycles, to be tested with scripts actually executed in a browser, and notes that trustHTML doesn't decide which code owns the script node.

    Sections 2 and 7 (website code, the shared Strong config and the two devtools packages) are marked as in progress in your PR, so we'll stay off them.

    🤖 Generated with Claude Code

  3. domgan-oai commented on Oct 14, 2026

    @domgan-oai
    Contributor

    Opened #2062 for the shared website configuration and independent website/devtools conversions.

    • Vite and CLI now share website/octane.config.ts. The actual CLI reports 0 findings across 97 authored website modules, including after fix(cli): follow a Strong dependency's own imports in Strong reports #2061; all 12 native/adapter devtools modules compile cleanly for client and server.
    • Traced the changed components to their real use sites and compared them with main: search, benchmarks, clipboard actions, theme/head/title, TOC navigation, Lynx previews, Playground, and all four devtools tabs. This caught and fixed first-paint TOC positioning, initial Playground URL-error timing, and idle devtools-tab snapshot delivery.
    • 103/103 website integration tests pass, covering dev SSR, production hydration, SSR smoke, and accessibility. The focused suites passed 483 tests; final devtools/navigation reruns and 29 post-fix(cli): follow a Strong dependency's own imports in Strong reports #2061 CLI/config tests also pass. The browser harness now starts its dev server with NODE_ENV=development; inheriting Vitest's test value had compiled TanStack's event client into a no-op.
    • Matching production builds measure 4,410,633 → 4,414,737 gzip bytes (+4,104, +0.093%) across the complete emitted static JavaScript collection, including public runtimes. This is Strong adoption, not a bundle-size improvement or proof of descriptor-free output.

    The remaining reported compatibility frontier is router (12 modules), Start (1), and three (2), with no React-compat boundaries. MDX conversion and the remaining package work stay separate under this issue. Paired checks also reproduced existing main issues with cached failed search imports, theme-color metadata, and a Lynx reload rejection; these are outside this conversion.

    Current-head CI is green on #2062: all 30 checks passed at signed head 5bff03b8d3f6daac30a7709bed9c1f65f83c52ba, including all 3 required checks. The website CI gate passed 104/104 tests, including its documentation-content test. CI run · paired benchmarks. The PR is ready and awaits maintainer review.

    Additional lifecycle checks confirm that recreating the public TanStack plugin three times retains the exact panel DOM and selected tab. The existing mobile cancellation test now holds the real closing animation until the replacement document commits; removing the stale-navigation guard only in the served browser module makes the same test fail with the old section hash. Both follow-ups preserve application source and keep the behavioral assertions intact.

  4. domgan-oai commented on Oct 14, 2026

    @domgan-oai
    Contributor

    Opened #2067 for the independent MDXProvider conversion. Both the client and server provider now use Strong .tsrx templates and forward children through their existing contexts. Public import paths and component-map behavior are preserved.

    Findings and validation against main 0bb503fc619303ef783fb1d52218186ae7984890. The final head is 9d157b9b0: direct-provider production browser checks used 00b59cf6b and the website production comparison used 854550e14. Follow-ups change declarations and the packed-consumer test harness; those runtime sources are unchanged:

    • Both provider modules pass Strong compilation, with no element-descriptor factory in their emitted output. This removes the provider's two ELEMENT_API findings; generated MDX documents still use descriptors and remain separate work.
    • Traced the actual consumers. The website does not mount MDXProvider: it imports the shared useMDXComponents path and passes table/pre overrides directly to its documents. Website checks therefore cover the real MDX pipeline, while a separate public-API fixture exercises the documented provider recipe using the existing MDX document/counter fixtures and genuine server/client compilation.
    • Paired provider browser tests pass in development and production on main and the PR: server DOM is adopted during hydration; nested inherited mappings update; disabling parent context restores the default heading while retaining the inner mapping; counter DOM and state survive mapping updates; events and unmount cleanup work. No console/page/recoverable hydration errors, and all three screenshot pairs are byte-identical.
    • Paired production website checks pass at desktop and narrow widths: homepage/docs navigation, direct SSR reload and hydration, tables, code-language labels, actual clipboard contents and feedback, and mobile menus. A mobile screenshot difference also reproduced on main; repeating the flow with interactions after opening animations completed produced matching captures. No product fix was needed.
    • 100/100 owning and adjacent tests pass across 21 MDX/Docusaurus test files. Package typechecks, plain-TypeScript public API consumers in Bundler and NodeNext modes, packed-package consumption, source-publication checks, and pnpm sync pass. Precise declaration companions preserve the existing plain-TypeScript API after the runtime entries become .tsrx.
    • Complete production client JavaScript: all 614 emitted public JS files, including copied runtimes, total 4,414,422 → 4,414,325 gzip bytes (−97) and 19,666,097 → 19,666,298 raw bytes (+201). This is a matched production-build comparison, with no runtime-speed claim.

    The first CI run exposed an existing packaging gap when MDX joined the strict packed-source matrix: the build-tool declaration imported MDX’s whole type entry, including evaluation types requiring global JSX. The fix derives the same mutable compile options from MDX’s exported compile-only entry and removes the ambient JSX shim. The public typetest now covers all four subpaths, option mutation, invalid-option rejection, and absence of global JSX.

    The packed browser lane also initially included the server implementation as a root. It now checks the client provider, while the Node lane checks both. Only that exact server root is excluded; real TypeScript 5.9/7.1 regressions prove a client import of server code still fails. 45/45 canary tests pass locally, and fresh packed MDX source passes both environment projects.

    All current-head checks are green on 9d157b9b0, including all three required checks and CI provenance: CI run, benchmark run. The four unit-test shards passed 53,936 tests (2 skipped), and website integration passed 104/104. The packed-source matrix passes with TypeScript 5.9.3, 6.0.3, and 7.1.0-dev.20260921.1: 51 bindings and 1,793 authored source checks per lane. React parity, browser integration, package publishing, typechecks, lint, examples, and bundle checks also pass. The benchmark report shows 64 work counters, 93 application-bundle byte values, and 120 public-import reachability values unchanged; all 20 timed operations remain within noise. The PR is ready for maintainer review.

    One audit limitation is unchanged: the generated browser-only whole-source typecheck also includes the server entry and reports 52 Node-global diagnostics in Octane's server source. Old and new provider sources produce byte-identical diagnostics under those options; public declarations and packed consumers pass. The server remains checked with Node types; no global JSX shim, skipLibCheck, or runtime workaround was added.

    This completes the provider portion once #2067 is merged. Generated MDX templates and the build-time override-list investigation, router/Start, Three, and final package declarations/enforcement remain under this issue.

    This comment was prepared and posted by a Codex agent.

  5. domgan-oai commented on Oct 14, 2026

    @domgan-oai
    Contributor

    Opened #2071 for generated MDX templates. Both _createMdxContent and MDXContent now compile as templates. strong forwards the application's policy, and overridableTags preserves full host overriding by default while allowing the website to specialize everything except its actual table/pre overrides. Core template HMR replaces the adapter's bespoke HMR shim.

    The final matched production comparison uses main 2d2bac446 and PR head c3719be8d. The merged package release is integrated; MDX/Docusaurus tests, types, production builds and browser checks were repeated. Independent source comparisons confirm that prior provider/HMR and owning DOM-work evidence remains applicable; earlier HMR screenshots retain the old version badge.

    • Actual consumers: 19 website MDX modules, comprising 16 documentation routes and three homepage samples. Desktop and narrow production checks cover their real SSR/hydrated content, client navigation, code labels and exact clipboard contents, tables, package tabs, filtering and all nine embedded Core API demos. All observable checks match main, including the released version label. 17/19 initial screenshots are byte-identical; differences were moving gallery content and tiny table raster variation. A settled real-navigation table recapture is byte-identical, with matching geometry and styles.
    • A real regression caught and fixed: SSR hydration preserved Build tools' table, but fresh client navigation lost its rows when DocTable forwarded native table sections. The owning runtime parser had parsed these roots inside a custom HTML wrapper, causing the browser to discard table markup. Parsing in template context and adding an inert wrapper fixes it. New core/MDX tests fail before the fix; browser checks preserve custom-element constructor/connection order, iframe ownership and hydration identity. All six applicable mount-work ratio guards pass; only one extra cold append is added per first fragment parse.
    • Provider and HMR parity: eight main/PR browser runs cover development/production and default/restricted mappings, exact hydration adoption, provider→prop precedence, retained counter state and cleanup. All 12 screenshot pairs match. Two actual website MDX edits retain surrounding state on both versions; a fresh SSR reload hydrates the latest edit. Final HMR uses the normal native watcher, with no manual invalidation.
    • Strong and descriptors remain separate evidence: all 19 generated modules compile under the website's Strong options without diagnostics. Parsed output has 14,353 → 0 descriptor-factory call sites. This covers those generated documents, not arbitrary authored expressions/imported components or the entire remaining website dependency graph.

    Matched complete production public JavaScript, including all 614 emitted JS files and copied runtimes:

    Metric Main PR Delta
    Raw bytes 19,667,507 19,400,827 −266,680
    gzip bytes 4,414,940 4,351,312 −63,628 (−1.44%)

    These are complete emitted .js/.mjs/.cjs totals, summed gzip level 9 per file; server output/maps/non-JS assets are excluded. Binary Lynx containers are tracked separately: raw unchanged, gzip +4 bytes. The CI paired benchmark records 64 unchanged work counters and no timing verdict outside its ±3% noise threshold across 20 operations. The required parser fix adds 5–44 B gzip to representative complete core apps (TSRX starter +10 B, JSX starter +30 B, full framework +14 B); the website total above includes that cost. No runtime-speed claim. Keeping every host dynamic still grows the independently gzipped highlighted modules (266,495 → 549,412 B); the restricted list measures 195,221 B. Those isolated module diagnostics are not the complete production metric above.

    Validation: 125 MDX/Docusaurus tests, 254 integrated core tests, public/package/scoped types, 45 packed-helper tests, source-publication checks, formatting, sync, and independent complexity/performance review pass. Current-head CI and the benchmark workflow are green on c3719be8d: all required checks and four parity shards, 54,057 sharded tests passed (two skipped), 616 Chromium tests, all 105 website tests including MDX HMR, and publication validation for 123 tarballs with strict TypeScript 5.9/6/7.1 consumer lanes. Bugbot found no issues.

    Remaining limits are explicit: nested mapped children follow Octane's opaque template-body contract (single literal children remain strings); native static-text hoists retain coarse source locations and maps omit embedded source content. Authored executable/diagnostic locations are tested. Both website builds also reproduce the same existing Lynx cleanup diagnostics when leaving a rendered native preview; no unrelated workaround was introduced. The candidate has zero failed requests; main cancelled 15 gallery PNG requests during desktop navigation, with none in its narrow run. These are retained as timing-dependent navigation observations.

    This completes the generated-document slice once #2071 merges. Router/Start, Three, and final package declarations/enforcement remain separate work under this issue.

    This comment was prepared and posted by a Codex agent.

  6. domgan-oai commented on Oct 15, 2026

    @domgan-oai
    Contributor

    Opened #2075 for the Router/Start website integration, using the existing /compiled Router entry. The website now selects matching compiled client/server Start entries, route generation and lazy imports through compiled: true.

    The entry now covers the website's actual root document shell, links, head assets, file/code-route factories and route-bound hooks. Shared behavior serves both entries; Wrap/InnerWrap stay on the ordinary compatibility path. Vite and Rsbuild retain explicit custom-entry precedence, and mixed Router runtime imports fail before the generator changes a route file.

    Actual-use testing caught two important lifecycle constraints:

    • Removing Link's flushSync changes the transition cue visible inside synchronous onBeforeNavigate. It is retained with a regression test.
    • A compiled keyed script list left row markers after Start's transport scripts removed themselves, causing whole-app hydration fallback. Both entries now share the existing unframed script descriptor list. A persistent test uses real router serialization and executes the actual transport scripts before asserting original DOM identity; it fails before the fix and passes afterward. Navigation script execution is tested separately. No hydration suppression or script-payload patch was introduced.

    The work also fixed a documented dynamic-style tooling mismatch: <style children={...}> and <style dangerouslySetInnerHTML={...}> now normalize through the existing shared parser pass before editor analysis. Raw scoped CSS remains intact; fixture client/server output is identical to main in development and production. Rsbuild now composes the existing TSRX-aware generator plugin, as Vite already does.

    Final matched production comparison: main ea438fb4 and PR 3a82a3e92, with identical dependency versions. Three fresh held-boot runs on each preserve the original HTML/head/body/app, shell, header, main and counter through hydration and clicks. At desktop (1280×900) and narrow (390×844) sizes, all six Router journeys, 16 documentation routes, three homepage samples and production/development Devtools flows pass. This covers intent preload, modified/keyboard links, history/hash/scroll, search and filter state, safe error arguments, 404s, metadata/JSON-LD, live Playground compilation, exact clipboard contents and embedded Core API interactions. Recorded semantic/geometry observations match. Of 25 paired screenshots, 24 are byte-identical; the remaining difference is confined to the automatically scrolling Lynx gallery.

    A public ordinary/compiled Router fixture separately verifies original input/button/header/script adoption, prehydration input, script nonce, no hydration replay, red → blue → red CSS and exactly six inline/external executions through home → next → home.

    Development HMR also matches main, with two distinctions:

    • Two real MDX edits preserve the original counter DOM/state; fresh edited SSR reloads hydrate and remain interactive.
    • Editing the native TSRX Devtools route retains the document/header but replaces and resets route controls on both revisions. Counter/reducer/filter/Profiler interactions then work, and fresh edited SSR reloads hydrate. The initial stronger retention assertion failed equally on main and the PR and is retained as evidence.

    These paired HMR runs used identical explicit polling. The candidate macOS native watcher missed the first file event in both in-place and atomic-save attempts, before any Vite update; those failures remain documented. No manual events or invalidation were used. Watcher/HMR inputs are unchanged by the PR, but local native-event parity is not claimed. All temporary edits were restored byte-for-byte, both worktrees are clean, and owned servers are stopped.

    Existing main behavior remains separate: static dark theme-color metadata can return during light-theme navigation; Lynx teardown can emit its existing errors; deliberately missing routes emit expected HTTP 404 diagnostics. The narrow run is viewport emulation, not physical-device evidence.

    Complete emitted public JavaScript, including all 614 .js/.mjs/.cjs files and copied runtimes:

    Metric Main PR Delta
    Raw bytes 19,401,613 19,409,270 +7,657
    Per-file gzip level 9 total 4,351,604 4,353,218 +1,614 (+0.037%)

    Four binary Lynx containers are separate: raw unchanged, gzip +10 bytes. The earlier smaller build failed hydration and is not the acceptance result. This is migration work, with no runtime-speed claim.

    Strong and descriptor findings remain separate:

    • The actual CLI reports zero findings across 98 website source modules. Start is no longer in its compatibility report, and there are no React-compat boundaries.
    • The consumed Router frontier is six modules: compiled/Matches, hookBindings, linkBinding, routerStateBinding, scriptComponent, and useStore. The two Three modules are unchanged. Whole Router source analysis is 33 diagnostics/0 parse errors across 73 modules; the six new Start modules are clean. Some otherwise-clean manual-slot hook modules remain undeclared because applying Strong changes their memoization emission and needs separate performance validation.
    • Parsed client/server output has no descriptor calls at the new Start and compiled route/Link adapter sites. The document shell still emits a descriptor plus scoped descriptor helpers, and the shared script owner emits host descriptors. The complete website is not yet descriptor-free or recursively Strong.

    Validation: 114 Router tests, 69 Start tests, 4 Rsbuild development/production cases, 261 compiler/style/parser tests, all 443 website unit tests, two focused development/production homepage browser cases, public/package/website types, formatting and sync pass. Independent complexity/performance review has no unresolved source finding.

    The final head is 014a36fac. Follow-ups after the matched browser build (3a82a3e92) change only validation configuration and tests: Start's tsconfig now includes its new authored .ts entries under the existing unused-symbol checks, and all 11 affected website test providers select the compiled entry. The homepage sample test already waits for a real mount-effect log; removing a redundant network-idle wait keeps every clipboard, selection, copy-feedback and pointer/keyboard assertion unchanged. The runtime, compiler and build-plugin sources are unchanged.

    All current-head checks are green on 014a36fac: CI run, benchmark run. All required and relevant checks, including CI provenance and Bugbot, pass; there are no unresolved review threads. The four unit shards passed 54,081 tests (two skipped), website integration passed 105/105 including generated MDX HMR, and Chromium integration passed 616/616. React parity, all example shards, lint, types, bundle checks and publication validation for 123 tarballs also pass.

    The paired CI benchmark records 64 unchanged work counters, 93 unchanged application-bundle byte values and 120 unchanged public-import reachability values. None of its 20 timed operations has a verdict outside the ±3% noise threshold. Those core benchmark fixtures are separate from the complete website build measurement above. The PR is ready for maintainer review.

    Publication CI validates the Router/Start tarballs and export/source shape. The separate strict external TypeScript source matrix still records Router as an existing exception and does not enroll Start (a framework integration, rather than a binding). Its green result is not new external strict-source proof for these two entries; package/public workspace typechecks and the actual website builds are the consumer validation here.

    Router's remaining timing/error/scroll/script boundaries, Three, and final package declarations/enforcement remain under #2059. This PR does not close the issue.

    This comment was prepared and posted by a Codex agent.

  7. domgan-oai commented on Oct 15, 2026

    @domgan-oai
    Contributor

    Three conversion is in #2080. Canvas now uses a Strong template, committed effect events and a coherent layout snapshot; core/hooks, root, store and loop opt into Strong without changing emitted behavior beyond the directive in all four client/server development/production modes.

    The website analysis remains clean across 98 source modules. Recursive traversal now leaves only web/events.ts in Three: its flushSync is retained because discrete event dispatch must observe synchronous scene removal. The existing event regression covers that contract; the homepage's native DOM drag handler is not a substitute for it. Canvas's parsed descriptor calls drop 2→0 client and 5→0 server. Router's six remaining modules are unchanged, so the website is not yet recursively Strong or globally descriptor-free.

    Actual homepage comparison: main a9dfdf7b5 versus the frozen PR runtime passed all 8 flows: main/candidate × development/production × desktop/narrow. Both used the same dependency graph and real Chrome WebGL2 (ANGLE Metal), not a mocked renderer. Verified original SSR DOM adoption; the actual two-mesh/three-light flame and rendered-pixel changes; mouse and emulated-touch capture/rotation; live reduced-motion changes; same-canvas resize and drawing-buffer sizing; navigation disposal/context loss; and a fresh working renderer after returning. Screenshots, videos, traces and source-hash receipts are retained with the Codex task. This is local browser/viewport evidence, not physical-device or deployed-site proof.

    The comparison exposed existing main behavior in both revisions: initial reduced-motion/offscreen rendering can continue, unrelated hero interaction can promote the deferred scene before scrolling, and Lynx teardown can emit its existing errors. These are recorded as follow-ups, not silently treated as fixed. No new failed requests or unexpected errors appeared.

    Complete production public JavaScript, including all 614 JS/MJS/CJS files and copied runtimes: 4,353,241→4,353,397 gzip bytes (+156, +0.0036%), raw +222 bytes. Deterministic per-file level-9 gzip sum; not an initial-load metric or runtime-speed claim. Four binary Lynx containers are unchanged.

    Local validation: 148/148 Three/differential tests, 17/17 browser tests, package/public/website types, upstream crosswalk, source-publication checks, formatting, changeset checks and sync. Strengthened existing tests catch stale callback/configuration and stale event-target reconnects. Independent complexity/performance review found no blocker; shipped source is +84/−79 lines with no new modules, exports or options.

    Local fresh install was blocked by the configured registry's unrelated table-package 403; the two local builds used the same verified reused dependencies. Hosted fresh-install results are reported below.

    All required and relevant current-head checks are green on signed 0c8a779fd: CI and benchmark workflow, plus Bugbot with no unresolved review threads. CI passed 54,091 unit tests (2 skipped), 105/105 website tests and 616/616 Chromium tests, all React parity/example shards, Three compatibility, lint/types and publication validation for 123 tarballs. Normal hosted dependency installation passed. The 51-binding packed-source matrix passed TypeScript 5.9/6/7.1 with/without Node ambient types; existing deferred cases remain explicit.

    The successful benchmark has one yellow timing observation: octane-tsrx select_lots +10.0%, 95% CI +8.9…+11.0%, medians 0.005783→0.006440 ms. That row fixture imports only Octane and does not exercise Three; its compiler/runtime, fixture and dependency inputs are unchanged. All 64 work counters, 93 application-bundle values and 120 public-import values are unchanged. The observation is retained without causal attribution or rerunning for a different result.

    The final signed head includes main's test-only warm-up fix; its five runtime files hash-match the paired browser build. This completes the Three conversion slice once merged. Remaining work includes Three's explicit event-timing boundary, Router's timing/error/scroll/script boundaries, descriptor elimination and final package declarations/enforcement. #2059 stays open.

    This comment was prepared and posted by a Codex agent.

  8. domgan-oai commented on Oct 15, 2026

    @domgan-oai
    Contributor

    Router's hook/store layer is in #2086 (signed head 235411f06).

    useStore.ts, hookBindings.ts, and routerStateBinding.ts now opt into Strong. APIs, manual hook slots, subscription/selector behavior, and stable navigation callbacks are preserved.

    Adding the directives alone disabled the existing production memo lowering. The compiler now lets validated manually slotted Strong modules use that path while retaining the rejection of generated Strong cache slots and the existing development/server/profile exclusions. All 12 paired helper emissions match main after normalization; 13 other Strong/manual modules also retain identical production output. Shipped package source is +9/−1, with no client runtime change.

    Validation findings:

    • 114 Router conformance/SSR/differential tests, 393 focused compiler/runtime/SSR tests, 2 benchmark-observer tests, and relevant source/public API typechecks pass. Subscription coverage includes atom replacement, stale-store isolation, and unmount cleanup.
    • The same Strong manual benchmark fails four guards with main's compiler and passes all 24 with the fix. Across 32 cache hits, the extra 128 function creations and 128 dependency-array creations fall to zero. These are source-creation events, not V8 heap bytes or a speed claim. The complete benchmark bundle changes +100 raw/−18 gzip bytes.
    • Actual website comparison against main c6cb71a covers development/production and desktop/narrow viewports. The integrated main 1b1f78d differs only in an MDX HMR test; production inputs are identical. The 24 original behavioral journeys verify held-boot DOM adoption, live counters, persistent shell/theme, intent/keyboard/modified links, docs params, same-route search and filter identity/history, browser Back/Forward, Playground hash replacement, Devtools, and errors/404s. After the follow-up config fix, all six candidate development journeys also pass stricter diagnostic assertions.
    • All eight public ordinary/compiled Router fixture flows pass: original input/button/header/script identity and prehydration input survive; inline/external scripts execute exactly through home→next→home without hydration replay; nonce, title, and route CSS match. Four settled-history checks restore exactly 360px for all 45 observed frames, with identical paired desktop/narrow screenshots.
    • The final config commit has byte-identical production output to the browser-tested build: every emitted JavaScript file and all four binary supplements retain their relative paths and SHA-256 hashes. Complete emitted public JavaScript includes all 614 JS/MJS/CJS files and copied runtimes: 19,409,867→19,409,663 raw bytes (−204), 4,353,393→4,353,381 summed per-file level-9 gzip bytes (−12). Four binary Lynx containers are separate: raw unchanged, gzip +3 bytes. This is not an initial-route payload or a meaningful size/speed improvement.

    CI exposed a pre-existing website configuration defect: pnpm isolation filtered out all ten transitive Devtools prebundle entries. Two owner-qualified imports now cover the host's complete lazy graph and the native event client. The isolated Vite proof contains two roots/five chunks with no unresolved imports; the final browser warmup needs no manual reload. Existing test assertions/timeouts are unchanged. The original hosted 504 and local cold-start pass remain recorded rather than being conflated.

    Evidence limits remain explicit:

    • Two initial candidate-only Build Tools <code> hydration warnings were recorded by the old behavioral harness. Their original served client module was not retained, so the cause remains unknown. The harness now fails on every hydration warning. Three fresh interactive captures and the final six dev journeys have none; the relevant client template, server markup, and hydrated DOM match main exactly. This does not establish that the original warning was fixed or was main behavior.
    • Back while native smooth scrolling is still running misses exact restoration on both revisions; the successful checks wait for native scrollend. Existing Lynx teardown diagnostics, initial theme-color behavior, and deliberate 404s remain separate. Narrow runs are browser viewport emulation, not physical-device or deployed-site proof.
    • The pre-follow-up local website suite passed 104/105; its generated MDX live-edit assertion timed out. The post-follow-up local run with CHOKIDAR_USEPOLLING=1 also passed 104/105 with the same timeout; hosted current-head Linux CI passed all 105, including both MDX edits. A paired main/candidate check reproduces the failure before any file event reaches Vite: disk changes but no invalidation, transform or WebSocket update follows. Actual options contain both usePolling:true and useFsEvents:true, selecting the latter handler. With external server.watch={usePolling:true,useFsEvents:false}, both revisions pass both edits on the first attempt, preserve original DOM/counter state, and pass fresh SSR/hydration with no console/page errors; sources are restored exactly. This bounds the local failure to file-event delivery on the selected backend, but does not explain the missing FSEvents notifications. No native macOS watcher fix is claimed.
    • Fresh local installation was blocked by the configured dependency firewall. Local builds reused a verified matching dependency graph; no registry bypass was used. Normal fresh dependency installation passed in current-head hosted CI, along with publication validation for 123 tarballs. Router remains an existing exception in the separate strict packed-source TypeScript matrix; local Router source/public typetests and real website builds are the relevant consumer checks here. Pristine upstream Router parity remains recorded-unverified; exercised differential/public-type lanes are not a claim of that separate coverage.

    Current-head CI passes all 27 jobs: 54,353 unit tests (2 skipped), 105/105 website tests, 616/616 Chromium tests, all React parity/example shards, lint/types, compatibility and publication checks. The current-head benchmark workflow also passes: all 64 work counters, 93 bundle values and 120 reachability values are unchanged. All 20 timing operations have no resolved verdict; wide confidence intervals do not establish speed equivalence or improvement. All required and relevant PR checks are green. Bugbot passes with no inline findings; maintainer approval remains required.

    The actual website Strong analysis passes all 98 authored files with zero diagnostics and no React-compat boundary. Its remaining dependency frontier is:

    1. Router src/compiled/Matches.tsrx
    2. Router src/linkBinding.ts
    3. Router src/scriptComponent.tsrx
    4. Three src/web/events.ts

    These boundaries, descriptor elimination, and final package declarations/enforcement remain under #2059. This PR does not close the issue.

    This comment was prepared and posted by a Codex agent.

  9. domgan-oai commented on Oct 15, 2026

    @domgan-oai
    Contributor

    Router's script ownership and hydration layer is in #2092 (signed head 732550f82).

    The shared ordinary/compiled Scripts owner now uses a Strong keyed template, preserving content/occurrence keys, attribute precedence, nonce and local script lifetime. The scroll-restoration owners use the existing permanent-static hydration range to preserve server-only contents, adopt existing DOM without replay and remove the script after hydration.

    A literal script template alone is inert on fresh navigation. The new static executeOnMount option prepares executable script sources once per parsed namespace and keeps existing clone/adoption paths. Ordinary non-resource script templates remain inert; existing async-resource behavior is unchanged; opted async scripts stay locally owned rather than being hoisted/deduplicated. Moving the existing static Hydrate body to a direct compiler import avoids retaining deferred activation/strategy code. Both Vite/Oxc and esbuild reachability controls now guard this boundary.

    Validation findings:

    • 183 focused Router/Start tests, 130 owning compiler/runtime tests, 773 nearby core tests and 347 static-boundary/consumer tests pass (these suites overlap). A separate Start Rsbuild run passes 4/4. Core/Router/Start/website source and public API typechecks pass; affected files are formatted and synchronization leaves a clean worktree.
    • Actual Chromium script tests pass in development and production: fresh inline/external execution, SSR no replay, nonce, original nodes and pretyped input, keyed reorder, cleanup/remount, nested/fragment templates, inert neighbors and async script ownership. Permanent-static browser controls also pass. Suspense insertion behavior matches the original descriptor control, including possible execution in an inserted hidden primary; no transactional no-execution guarantee is claimed.
    • Matched actual website testing of 107c05b9 against main 3691ea2b, using the real dev server and production build, passes 24/24 journeys across both revisions and desktop/narrow viewports. It covers held client boot and SSR adoption, live counters, persistent shell/theme, links, route params, filters/search/history, Back/Forward, Playground, Devtools and missing/error routes. All 8 actual pre-boot scroll checks restore 610px before client boot, retain original DOM, remove the restoration script afterward and restore 610px on Back without reinsertion.
    • All 24 public document cases pass across both revisions: ordinary/compiled Router, development/production, plain Router and real Start string/stream transport. Enforced nonce CSP, pretyped input and original input/button/header/script identity survive; inline/external scripts produce the exact six navigation events through home→next→home with no hydration replay. Stream responses are consumed to completion before browser serving, so delayed-chunk timing is not covered.
    • Bugbot found TS-wrapped static booleans were rejected. The final follow-up reuses the existing unwrap helper, accepts erased assertions/satisfies/non-null wrappers and still rejects dynamic values. The regression fails before the fix; 130 tests, 4 Chromium cases and 68 public-compiler probes pass afterward. All 16 previously accepted script outputs remain byte-identical. The final build accounts for all 614 JavaScript assets: 582 are unchanged; 31 differ only in hashed filename references; the remaining Playground compiler chunk contains the wrapper fix. Reversing those differences reproduces every retained previous asset digest. Final affected-consumer checks on cd0bf12c2 pass 10/10: dev/prod hydration adoption, paired real Playground edits/previews and settled desktop/narrow navigation. This qualifies the earlier full matrix; it does not claim every matrix case was rerun after the compiler fix.
    • The complete final production public JavaScript inventory, including all 614 JS/MJS/CJS files and copied runtimes, is 19,411,562→19,405,173 raw bytes (−6,389), and 4,353,883→4,352,424 summed level-9 per-file gzip bytes (−1,459). Four Lynx binary containers are separate: raw unchanged, gzip +5 bytes. This is not an initial-route payload or a runtime-speed claim.
    • Deterministic DOM-template work and semantic hashes match main exactly; all 6 owning ratio guards pass. 101 cold-probe mounts retain one parse/101 clones; opt-in adds one detached source script, with 101 executions and zero retained scripts after cleanup. Isolated complete esbuild consumer sizes retain the tradeoff: ordinary Router +2,109 gzip bytes, compiled Router −1,149; these are diagnostic consumers, not whole-website payload or speed claims.

    Evidence limits are retained: no hydration warnings or request failures occurred. Both revisions produce the same existing Lynx teardown diagnostics and intentional 404 console messages. Immediate Back during an in-flight native smooth scroll misses exact restoration on both revisions; after native scroll completion, both restore the original position and preserve shell/control identity. Settled desktop and narrow screenshots are byte-identical; original in-flight captures remain retained. Narrow runs are browser viewport emulation, not physical-device/deployed-site proof.

    Fresh local installation was blocked by the configured dependency firewall; local checks used a fingerprint-verified matching dependency graph without a registry bypass. The initial broad binding invocation had two macOS watcher errors despite 197 passing assertions; the isolated unsandboxed serialized Rsbuild run passes. Existing fixture-only type errors reproduce on main; normal affected project/public-type programs pass. Pristine upstream Router parity remains recorded-unverified. The selected binding audit was refreshed and genuinely reassessed against current main; its final report is current, with 148 unchanged Router files and five intended differences.

    CI initially passed 104/105 website cases; the first-router-event case timed out waiting for network idle even though its client mount effect was visible. The final test-only correction waits for that existing visible effect using the existing budget. Event processing, DOM identity and error assertions are unchanged. The focused test passes, and all eight paired main/candidate dev/prod probes pass, including controlled unrelated pending requests. Four SSR probes confirm the readiness signal is client-only. CI did not capture its pending request, so the controlled probe is not an attribution of that original timeout. Final production inputs are unchanged from the browser-tested cd0bf12c2 build.

    Current-head CI passes all 27 jobs on signed 732550f82: 54,418 unit tests (2 skipped), 105/105 website tests and 618/618 Chromium tests. All React parity/example shards, lint/types, bundle-size checks, Three/Lynx compatibility and publication validation pass. Normal hosted dependency installation passed; publication validates 123 tarballs preserving 1,187 raw TSRX files. The separate strict TypeScript 5.9/6/7.1 matrix validates 51 bindings and 1,793 file checks per version, retaining Router's existing exception; this is not new strict external-source proof for Router/Start. All required and relevant PR checks are green. Bugbot passes with its actionable thread fixed and resolved, and no unresolved review threads remain. The PR is ready and mergeable; maintainer approval remains required.

    The current-head benchmark workflow passes. All 64 work counters are unchanged; all 20 timing comparisons have the report's “within noise” verdict, which is not a speed or equivalence claim. The 13 complete application-JavaScript gzip metrics increase 9–20 bytes each (+48 raw bytes): Oxc Threadline/Pagecraft +16/+15 gzip bytes, esbuild +19/+13. The full-export framework fixture grows 179 gzip bytes. Of 40 public-import gzip metrics, 23 grow 14–22 bytes and 17 are unchanged. These small costs are retained alongside the separate complete-website reduction above.

    All 98 authored website files pass Strong analysis with zero diagnostics and no React-compat boundary. The remaining dependency frontier is now:

    1. Router src/compiled/Matches.tsrx (remaining match/ref/lifecycle work)
    2. Router src/linkBinding.ts
    3. Three src/web/events.ts

    These boundaries, broader descriptor elimination and final package declarations/enforcement remain under #2059. This PR does not close the issue.

    This comment was prepared and posted by a Codex agent.

  10. domgan-oai commented on Oct 15, 2026

    @domgan-oai
    Contributor

    Follow-up to #2092: review feedback changed the implementation and supersedes the public-API and size figures in the earlier update.

    The script capability is now compiler-internal (__executeOnMount), with no public JSX option or user-facing documentation. Preparation belongs only to script tokens; the ordinary template path matches main and the prior universal +48 raw-byte cost is removed. Router filters the reserved key from runtime attributes, and external route scripts retain browser dynamic-insertion ordering. A matched isolated fixture using the Router script owner is +2,200 gzip bytes for the ordinary Router entry and −1,055 for compiled. The complete production website’s 614-file JavaScript inventory is −1,319 summed per-file gzip bytes versus main; neither figure is a runtime-speed or initial-route-payload claim.

    Against main 3691ea2b, final-source actual website hydration/navigation and preboot scroll restoration pass in development and production at desktop and narrow widths. All 98 authored website source files analyze without Strong diagnostics; recursive traversal still reaches Router compiled/Matches.tsrx, Router linkBinding.ts and Three web/events.ts. CI on signed head 86a051348 passed all 27 jobs (54,421 general tests, two skipped; 105 website; 620 Chromium), including the Router and SSR-query parity type programs. The benchmark confirms all 13 complete application-JavaScript gzip metrics and all 64 work counters unchanged, while the full-export framework fixture grows 213 gzip bytes and one of 20 timed operations is flagged slower (+8.6%). The PR description records the limits and remaining costs.

    Agent-authored update.

  11. domgan-oai commented on Oct 15, 2026

    @domgan-oai
    Contributor

    Router’s compiled match/error lifecycle is in #2102.

    The match projection and shared default error UI now compile in Strong mode. Live provider/transition acknowledgement, lazy loading, pending transaction ownership, synchronous onCatch/rethrow/reset, and scroll lifecycle remain explicit compatibility owners. This keeps the existing boundary hierarchy and observable callback timing instead of weakening error handling to satisfy analysis.

    Matched actual website testing against main 9bceb816a passed in development and production: decoder → catalog/filter → another decoder, direct invalid-code 404, authored homepage recovery with a working counter, Back/Forward, and Docs. Each flow had exactly two document requests, for the deliberate direct entries; all other navigation, recovery, and history transitions stayed client-side. Server-rendered decoder content and hydration transport matched, and controls were interactive. The invalid-code page throws notFound() in beforeLoad; render-thrown callback/rethrow and match-identity recovery are covered separately by Router tests. No Router/hydration diagnostics appeared; the same existing Lynx teardown diagnostics occurred on both revisions. This was one desktop-sized in-app browser surface, not a deployed-site or physical-device test, and original DOM-node identity across hydration was not instrumented.

    Local validation passed 106 Router conformance, 10 SSR, and 3 differential tests, plus Router source/public API and website source typechecks, changed-file formatting, production build, and pnpm sync. Added lifecycle scenarios passed unchanged on main and candidate; negative controls disabling reset/reporting failed. A separate global-boundary navigation promise stall reproduced on both revisions. Pristine upstream Router parity remains recorded-unverified. The complete production public JavaScript inventory was 615 files on each revision: 19,405,558 → 19,405,775 raw bytes (+217), 4,355,712 → 4,355,894 summed per-file level-9 gzip bytes (+182, +0.0042%). This is neither initial-route payload nor a speed claim.

    All 98 authored website modules still analyze with zero Strong diagnostics and no ReactCompat boundary. The original 10,172-byte compatibility compiled/Matches.tsrx becomes a 5,388-byte Strong projection plus explicit 2,840-byte provider and 3,604-byte lifecycle compatibility owners. These are source-file counts, not bundle reduction. The named recursive dependency frontier therefore changes from three to four modules: Router compiled/RouterProvider.tsrx, compiled/MatchLifecycle.tsrx, linkBinding.ts, and Three web/events.ts. Descriptor elimination, package declarations/enforcement, and those remaining compatibility owners stay open under #2059.

    Current-head CI passed all 27 jobs on 0d3284b6a: 54,426 general tests passed (2 skipped), 105/105 website, 620/620 Chromium, and all parity, example, lint/type, bundle, compatibility, and publication lanes. Benchmark passed: all 64 work counters, 93 bundle values, and 120 reachability values were unchanged; all 20 timings had no resolved verdict, so this does not establish speed equivalence. Bugbot passed with no inline findings. The PR is ready and mergeable; maintainer review remains required.

    Agent-authored update.

  12. domgan-oai commented on Oct 15, 2026

    @domgan-oai
    Contributor

    Router Link transition ownership is in #2107 (signed head b9b5ea835).

    The shared Link binding now opts into Strong mode and publishes its transition cue through an internal state-bound committed setter before synchronous navigation callbacks. Its ordinary resolution update remains batched. A same-owner pending transition is promoted through the existing urgent path; unrelated deferred transition work is no longer forced through an all-priority global flush. Other eligible urgent work and queued effects can still commit, including across roots, and affected ViewTransition ownership follows the normal scheduler rules. The paired Octane/Router release keeps the internal binding primitive available to consumers.

    Matched actual website testing against main 91dae8d739 passed in development and production at desktop and a 390×844 mobile viewport: hydrated Quick start controls, modifier/new-tab and ordinary links, keyboard pagination, history and active state, header navigation, focus-intent Playground preload, and mobile docs-menu closure. Link activations stayed client-side. No HTTP failures or browser warnings/errors occurred. One extra candidate development document request occurred during initial startup before interaction and did not recur on a warm direct entry; its cause is unassigned. Website DOM identity was not instrumented, and the mobile run was viewport emulation.

    Local Router client/SSR/differential tests passed 121/121. Core scheduler, transition and scoped ViewTransition coverage passed, including synchronous callback-visible cue and ancestor state, hydration adoption, same-owner promotion, deferred work, and affected-scope animation selection; targeted negative controls detected ordinary batching and blanket flushing. Owning package typechecks, coordinated-release policy checks, pnpm sync, scoped formatting, and production build passed. The final source build's complete 615-file public JavaScript inventory was +320 raw bytes and +454 summed per-file gzip-9 bytes versus main (+0.0104% gzip); this is not initial-route payload or an interaction-speed claim. A no-Router state-hook fixture remained byte-identical.

    All 98 authored website modules retain zero Strong diagnostics and no ReactCompat boundary. The recursive compatibility dependency frontier falls from four to three modules: Router compiled/MatchLifecycle.tsrx, Router compiled/RouterProvider.tsrx, and Three web/events.ts. The Link binding retains two non-blocking explicit-dependency hints because its manually slotted hooks need those arrays. Descriptor elimination and package declarations/enforcement also remain open under #2059.

    The current-head benchmark passed: all 64 work counters were unchanged, and all 20 timing comparisons were within noise, which does not establish speed equivalence. The full-framework fixture grew 398 raw / 110 gzip / 163 Brotli bytes; three public-import compressed metrics grew 1–3 bytes, and the other 87 bundle and 117 reachability values were unchanged. These fixtures are separate from the complete website inventory above.

    Current-head CI passed all 27 jobs, including 105/105 website and 620/620 Chromium tests. Attempt 1 failed one independent-island hydration assertion after a fresh click; the unchanged signed head passed the 54-test production file locally and on the failed-job rerun (16,171 shard tests passed, 2 skipped), and the exact base CI had also passed the file. The fixture does not call the new Link hook; its immediate assertion can race passive replay cleanup. This is a likely timing race, not a verified historical flake. All required checks and Bugbot are green; maintainer review is still required.

    Agent-authored update.

  13. domgan-oai commented on Oct 15, 2026

    @domgan-oai
    Contributor

    Three’s discrete-event ownership is in #2111.

    The default web event manager now uses an internal renderer-listener boundary instead of global flushSync. Ordinary DOM updates from a discrete mesh event commit before the native listener returns, including during an unrelated async Action; unrelated task-held transitions are not admitted. Renderer priority is independent of delegated DOM propagation, preserving nested controlled-input restoration. An implicit first root mount waits until the listener boundary, avoids native ViewTransition routing, and is visible to the next listener. Explicit transitions retain scheduler ownership; eligible ordinary work and effects can still commit across roots, so this is not root isolation.

    Matched production website testing compared clean main d65e896 with signed PR head 2c48e67. Both hydrate the offscreen homepage flame to live WebGL2 after scroll, animate and drag with matching cursor changes, suppress idle rotation under reduced motion while retaining drag, and navigate client-side with the canvas detached. Neither had flame-phase errors or failed/HTTP-error requests. Both showed the same pre-existing Lynx worker teardown errors after navigation. The flame uses native canvas listeners, so it does not prove raycast mesh-handler timing by itself.

    The separate real WebGL mesh fixture proves the cross-renderer timing: main and the PR show selected to a later native listener and immediately after dispatch; a deletion-only control remains idle until the microtask. The final-head affected Three browser file passed 9/9. Focused scheduler/Action/dispatch tests passed 158/158 across development and production, Three event/differential tests passed 24/24, release-policy tests passed 28/28, affected source and Three owning typechecks passed, and pnpm sync left the worktree clean. Negative controls detected unrelated global transition flushing, delayed DOM updates, nested controlled-input restoration, early first mounts, and unwanted native ViewTransition admission.

    All 98 authored website modules retain zero Strong diagnostics and no ReactCompat boundary. The recursive dependency frontier falls from three modules to two: Router compiled/MatchLifecycle.tsrx and compiled/RouterProvider.tsrx. Descriptor elimination and final package declarations/enforcement remain open.

    The complete production public JavaScript inventory remains 615 files: +325 raw bytes and −397 summed per-file gzip-9 bytes against main. A no-Three state-hook fixture is +51 raw / +14 gzip / −67 Brotli with identical behavior and module inventory. These figures are not an initial-route payload or speed claim. Pristine upstream React Three Fiber parity was not established by the focused local checks.

    Current-head CI passed all 27 jobs on 2c48e67: 54,442 general tests passed (2 skipped), 105/105 website tests, 622/622 Chromium tests, and the parity, example, Three-compatibility, lint/type, bundle, and publication lanes. Bugbot passed with no review findings, and the separate preview workflow succeeded. The benchmark report passed with all 64 work counters unchanged and all 20 timing comparisons within noise; that is not a speed-equivalence claim. All 13 complete application-JavaScript gzip metrics grew by 15–87 bytes, including +25/+15 for the Oxc Threadline/Pagecraft fixtures and +39/+66 for their esbuild counterparts. The full-export framework fixture grew 262 raw / 79 gzip bytes. This shared-runtime cost is the tradeoff for preserving renderer-event timing without reusing DOM propagation ownership.

    #2111 was merged as 5dc82f5. This update was prepared and posted by a Codex agent.

  14. domgan-oai commented on Oct 16, 2026

    @domgan-oai
    Contributor

    Router’s compiled provider and navigation acknowledgement ownership is in #2113 (signed head 6b1676c).

    Compiled Start now uses a router-only PreconfiguredRouterProvider. The existing compiled provider still synchronously applies option props and keeps the same route subtree when those props change. The mounted Router owns its transition callback; ordinary and compiled match trees share presentation of Router Core’s exact offered match snapshot and acknowledge it after commit. Superseded or abandoned work resolves false, and history/transition ownership follows the mounted router. Pending/error/scroll lifecycle and lazy loading remain compatibility-owned.

    Matched production website testing compared exact main 5e63f5e with signed head 6b1676c: all nine normalized route/DOM states and 33 Router events matched across hydration, links, history, scroll restoration, and rapid supersession, with one document request each and no hydration warnings. The raw SSR document starts identically with no marker before <html>. Both runs reproduced the same two pre-existing Lynx worker loadScript page errors after leaving the homepage; functional assertions passed, but a blanket zero-page-error assertion failed on both.

    Focused local validation passed 34 Router tests, four Start document-hydration tests, one ordinary Router document SSR test, public compiled-entry typetests, scoped source typechecks, formatting, production build, and pnpm sync. Negative controls detected premature acknowledgement, installation after descendant layout, and leaked history ownership. The local root Vitest config could not initialize under the filtered install because it resolves unrelated packages; the focused tests used equivalent scoped project configurations. Explicitly forcing the changed tests into a temporary type program produced seven identical diagnostics on main and candidate; the owning CI program excludes those test files. Pristine upstream parity remains recorded-unverified.

    All 98 authored website modules remain free of Strong diagnostics and ReactCompat boundaries. The recursive compatibility frontier drops from two modules to one: Router compiled/MatchLifecycle.tsrx. The generated routes still call the compatibility lazy loader, so this does not establish descriptor elimination or a wholly Strong dependency graph. Package declarations/enforcement also remain open under #2059. The complete emitted public JavaScript inventory remained 613 files: +217 raw bytes and +85 summed per-file gzip bytes versus main; this is not initial-route transfer size or a speed claim.

    Current-head CI passed all 27 jobs on 6b1676c: 54,446 general tests passed (2 skipped), 105/105 website tests including 77 SSR/hydration end-to-end cases, and 622/622 Chromium tests. The owning root typecheck, Router public typetests, parity, examples, bundle, and publication lanes passed; Bugbot passed without findings. The benchmark report passed with all 64 work counters, 93 bundle values, and 120 public-import reachability values unchanged; all 20 timed comparisons were within noise, which does not establish speed equivalence. The PR is ready and mergeable; maintainer review remains required.

    Agent-authored update.

  15. domgan-oai commented on Oct 17, 2026

    @domgan-oai
    Contributor

    Compiled scroll-restoration ownership: #2129 moves the script owner out of compiled/MatchLifecycle.tsrx and into the existing Strong match tree without changing its root-child placement or public API. The function-valued location predicate must stay live: a verbatim move let Strong cache it by stable Router identity, so the final form preserves main’s eager evaluation and three-slot client memo structure.

    Actual production website comparison against main 175b85d: both builds restored a seeded 640px before hydration while client assets were gated; executed the same SSR script once; removed it during hydration while preserving header/main identity and scroll; reset on the Benchmarks link; restored 640px on Back and 0 on Forward; and restored/focused #async-ui for direct and in-page anchors. Each independent flow made one document request, with no console/page errors or hydration warnings. The complete emitted public JS inventory stayed at 619 files (+23 raw / +20 summed per-file gzip bytes; not route transfer size).

    The same focused hydration suite passed 9/9 on main and the candidate, and the owning Router/SSR suites passed 141/141 locally. A missing-client-arm negative control produced the expected hydration mismatch. Tracked website Strong analysis remained 54 authored modules with zero diagnostics and the same MatchLifecycle.tsrx compatibility dependency: pending/error ownership still reaches it, so this narrows ownership without claiming a compatibility-module-count reduction or whole-package compliance.

    Current-head CI is green at d28e75e, including website integration, Chromium integration, test and parity shards, package validation, typecheck, lint, bundle size, and the benchmark report. The PR is ready for review and still requires approval.

  16. domgan-oai commented on Oct 17, 2026

    @domgan-oai
    Contributor

    Compiled pending-transition ownership: #2132 moves CompiledPending into the Strong compiled match tree. Only the waiting pending-match path takes a match-store snapshot of the active transaction completion; fallback-only and client-only paths retain their behavior. Synchronous error reporting remains in MatchLifecycle.tsrx.

    Actual production website comparison on main 59e83ac3 and PR head a3c8cc1b (bundled Chromium 149): two flows matched all 10 normalized state snapshots and route-event order. Holding the cold Benchmarks script kept Core APIs visible during navigation; release rendered Benchmarks and Back restored Core APIs. When Docs superseded it before release, Quick start remained the winner after the old request and transaction settled. Each flow made one document request and one gated script request, retained the shell, and reported no page, console, hydration, or request errors. The website retained prior successful matches while the asset was pending, so this validates integration; the controlled Router test directly covers pending-to-pending supersession. Complete emitted public JS stayed at 619 files (+64 raw / +29 summed per-file gzip bytes; not route transfer size).

    Focused candidate coverage passed 32 client and 12 SSR tests, and the new two-pending-navigation scenario also passed against exact main. A lost-fallback negative control failed as expected; the test does not independently establish every internal transaction-identity strategy. Tracked website Strong analysis remained 54 authored modules with zero diagnostics and the same compatibility dependency because error ownership still reaches it. This is a narrow ownership conversion, not whole-package Strong compliance or descriptor elimination.

    Current-head CI is green at a3c8cc1b: the full CI run completed successfully, including website integration, Chromium integration, four test shards, four React parity shards, typecheck, lint, publishability, examples, and bundle checks. The benchmark report passed. PR #2132 is ready for review and still requires human approval.

    Agent-authored update.

  17. domgan-oai commented on Oct 19, 2026

    @domgan-oai
    Contributor

    Router compiled failure/error-boundary ownership: #2160 moves fallback selection/presentation into the Strong match tree and gives the active catch arm synchronous once-per-entry reporting. Route/global boundary topology, ancestor propagation, targeted not-found placement, and match-identity reset remain intact.

    Matched production website validation against main 3c8272e52: a one-shot render failure on the real Benchmarks route reached the affected code on both builds; all six observed states matched, with no browser errors. Back alone left two fallback views on both builds (pre-existing); reload recovered Core APIs and a real Docs link reached Quick start. Focused suites: 44 core, 44 Router client/hydration/navigation, 12 Router SSR; the two changed Router contracts also passed against main.

    The same 54 tracked website components went from one recursive compatibility dependency (compiled/MatchLifecycle.tsrx, reached by three website modules) to zero, with zero analyzer diagnostics on both sides. This completes that measured website dependency frontier; it does not establish whole-package Strong compliance or descriptor elimination. The complete production public-JS inventory increased by 1,143 raw / 290 summed per-file gzip bytes, and the focused suspense-transition scenario increased by 32 gzip bytes.

    Full CI and the benchmark passed on PR head e0db2ad7e. The benchmark kept all 64 work counters unchanged, but flagged one replace timing (+8.3%, 95% CI +3.1% to +21.4%). Matched local builds of that exact benchmark target were byte-identical; the CI executable was unavailable, so the timing signal remains unattributed. CI measured +35 gzip bytes for suspense-transition and +36 gzip / +155 brotli bytes for Pagecraft Oxc.

  18. trueadm commented on Nov 10, 2026

    @trueadm
    CollaboratorAuthor

    Done. Both halves are complete.

    Strong compliance (#2400):

    • Strong is on for the website's own modules and its MDX documents, with no "use strong" exceptions.
    • octane analyze --strong-dependencies lists no packages and no ReactCompat boundaries.
    • The website sets compiler.strongDependencies to { require: true, allow: [] }.

    No descriptors. The open question is settled: value-position and returned JSX stay valid in Strong. They compile to a hoisted _frag$N template, rendered through a compiler 'r:' record, so the criterion is restated as follows. The website's client build calls no element-descriptor factory except to build those 'r:' template records.

    Both. CI passed on #2400, #2405 and #2409, including website e2e, the conformance and parity suites, and the example apps.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions