Skip to content

fix(codemod): report retained React callback hooks - #2607

Merged
domgan-oai merged 1 commit into
octanejs:mainfrom
openai-oss-forks:codex/codemod-retained-react-callback
Nov 13, 2026
Merged

domgan-oai merged 1 commit into
octanejs:mainfrom
openai-oss-forks:codex/codemod-retained-react-callback

Conversation

@domgan-oai

@domgan-oai domgan-oai commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Fixes #2606.

A migrated native component can call an unchanged local helper whose first direct call uses React's useCallback. The codemod missed this case even though the React export requires a React dispatcher.

Include useCallback in the existing named React hook proof. Keep the output and the caller reachability rules intact.

Validation

  • Targeted pnpm format:files:check
  • Codemod package TypeScript check
  • pnpm test
  • All 192 codemod project tests passed. The ordinary CLI regression fails on upstream and passes after the fix in both project-type modes. It also checks a shadowed alias and a call after an earlier throw.
  • The public synthetic fixture renders under production React SSR and throws at the genuine React useCallback export under Octane SSR before the diagnostic fix.
  • perf-review. The change is confined to codemod analysis.
  • concise-code. Extend the existing first-call name check. A general hook-name match would include APIs that do not require a dispatcher, and the broader setup fallback can flag unreachable calls.
  • pnpm sync

The matched 7,902-file run used project types, compiler verification, SVG paths and no private recipes.

GitHub CI and the benchmark passed on 11653ed2 before squash merge 6ed8f74c. The exact signed-head replay finished at 1,381 of 7,902 clean Strong files with zero changed report rows. The exact merged-main replay returned the same count and zero changed report rows. The merged tree is identical to the rewritten history at 8c2e32c3.

Risk / follow-ups

The check covers a named React import at the existing proven direct call site. It does not infer a call through a later statement or wrap the retained helper.

Provenance

  • An agent produced this diff (agent-authored)

Codex task · Host com-79386


Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.


Note

Low Risk
Narrow codemod analysis change with added regression tests; no runtime migration or auth/data paths affected.

Overview
The codemod now treats useCallback like the other dispatcher hooks when it inspects unchanged local helpers. If a migrated native component calls such a helper during render setup, it emits the existing bindings error instead of letting the case slip through.

Detection is wired into the same first-direct-call path as useContext, useState, and useSyncExternalStore: source prefilter plus directRendererCalls name check. Project tests add use-callback fixtures and expect Callback.tsx to report useLabel → React useCallback.

A patch changeset documents the @octanejs/codemod release note.

Reviewed by Cursor Bugbot for commit 11653ed. Bugbot is set up for automated code reviews on this repo. Configure here.

@github-actions github-actions Bot added agent-authored Diff or issue body substantially produced by an AI agent fix PR: bug fix labels Nov 13, 2026
@domgan-oai
domgan-oai marked this pull request as ready for review November 13, 2026 19:12
@github-actions

Copy link
Copy Markdown
Contributor

Benchmark report

🟢 No byte growth, no added work, and no timing changes beyond ±3%.

Compares 150f8e238, the merge commit's first parent with 21b9595a8 on the same runner. Any increase in a js-framework work counter fails this check; byte changes are a report. Wall time is a report: base and head samples alternate in one browser, and an operation is called slower or faster only when the 95% confidence interval of its ratio excludes ±3%. Workflow run

js-framework: 1k/10k row operations

All 20 timed operations (20 without a verdict)
target operation base ms head ms head/base 95% CI
octane-tsrx run 3.375 3.467 ±0.0% −6.1% … +6.1% ⚪ within noise
octane-tsrx replace 10.208 10.125 +0.9% −15.2% … +13.8% ⚪ within noise
octane-tsrx add 2.917 2.975 ±0.0% −1.1% … +5.4% ⚪ within noise
octane-tsrx update 0.087 0.089 −1.0% −3.7% … +2.6% ⚪ within noise
octane-tsrx select 0.007 0.008 +2.5% −0.5% … +9.5% ⚪ within noise
octane-tsrx swap 0.023 0.022 +0.6% −1.8% … +4.8% ⚪ within noise
octane-tsrx remove 0.020 0.019 +0.7% −8.5% … +5.1% ⚪ within noise
octane-tsrx runlots 23.458 24.133 +0.4% −2.5% … +3.4% ⚪ within noise
octane-tsrx select_lots 0.007 0.007 +2.3% +1.2% … +3.4% ⚪ within noise
octane-tsrx clear 51.133 52.283 +0.6% −0.5% … +2.2% ⚪ within noise
octane-jsx run 4.767 4.300 ±0.0% −16.3% … +6.0% ⚪ within noise
octane-jsx replace 8.592 8.092 +1.3% −3.8% … +7.4% ⚪ within noise
octane-jsx add 4.008 3.967 +3.0% −4.1% … +15.2% ⚪ within noise
octane-jsx update 0.218 0.251 +8.5% −4.6% … +22.1% ⚪ within noise
octane-jsx select 0.128 0.120 −6.8% −20.9% … +7.0% ⚪ within noise
octane-jsx swap 0.167 0.170 +0.8% −4.4% … +9.3% ⚪ within noise
octane-jsx remove 0.161 0.149 −1.9% −11.3% … +6.6% ⚪ within noise
octane-jsx runlots 29.350 29.033 +2.7% −1.1% … +4.6% ⚪ within noise
octane-jsx select_lots 0.996 0.989 +0.0% −2.0% … +2.3% ⚪ within noise
octane-jsx clear 57.483 57.700 +0.7% −0.9% … +2.1% ⚪ within noise

All 64 work counters are unchanged.

Application bundle size (bytes)

No changes across 111 measured values.

Public-import reachability bundles (bytes)

No changes across 141 measured values.

@domgan-oai
domgan-oai merged commit 6ed8f74 into octanejs:main Nov 13, 2026
54 checks passed
domgan-oai added a commit that referenced this pull request Nov 13, 2026
* feat: let packages declare Strong mode and applications require it (#2400)

* feat: let packages declare Strong mode and applications require it

Packages declare Strong in package.json with "octane": { "strong": true }
or a list of paths. compiler.strongDependencies: { require, allow } fails the
build with OCTANE_STRONG_DEPENDENCY when an application module reaches a
non-Strong module in another Octane package or an octane/react boundary. The
walk moves from the CLI into the compiler, so octane analyze previews exactly
what the build rejects.

The six packages the website renders declare their Strong modules, and the
website turns require on with an empty allow list. Its playground version
picker replaces @octanejs/base-ui's Combobox with a local listbox.

Refs #2059

Co-Authored-By: Claude <[email protected]>

* fix: address review on Strong dependency requirement

- Vite plugin: always read octane.config.ts, so strongDependencies is not
  dropped when strong and renderers are both passed inline.
- octane analyze: keep going under require when there are no views, so plain
  application modules are still checked.
- Playground version picker: keep focus in the input on any press inside the
  list, not only on option rows.

Co-Authored-By: Claude <[email protected]>

* fix(website): let the version list's scrollbar scroll

A mousedown preventDefault on the scrolling list also blocked its scrollbar.
The list now takes focus itself (tabIndex -1), and the field closes the popup
only when focus leaves it. Choosing an option returns focus to the input.

Co-Authored-By: Claude <[email protected]>

* fix(website): close the version list through the bubbling onBlur

Octane's onBlur is delegated as focusout, as React's is, and it is the
typed name; onFocusOut is not.

Co-Authored-By: Claude <[email protected]>

* fix(website): return focus to the version input on Escape

The list can hold focus, so hiding it on Escape dropped focus to the page.

Co-Authored-By: Claude <[email protected]>

* fix(compiler): name the Strong dependency code in its message

The printed-code audit rejects interpolating a non-diagnostic `.code`.

Co-Authored-By: Claude <[email protected]>

* test(website): expect the package reason in Strong module status

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* feat(codemod): migrate verified path-only SVG components (#2398)

* fix(codemod): trace SVGs through native renderable props (#2402)

* feat(codemod): migrate verified path-only SVG components

* fix(codemod): trace SVGs through native renderable props

* fix(codemod): follow proven renderable TypeScript wrappers

* fix(signals): replay optimistic$ updaters over newer source values (#2401)

* fix(signals): replay optimistic$ updaters over newer source values

An overlay kept the value its updater produced at write time, so a refetch,
stream value or direct write stayed hidden behind a pending edit, and a
rejected operation's edit survived inside a later operation's value. Keep
each operation's writes and replay them in order over the current source,
as useOptimistic rebases its updates.

* fix(signals): show an optimistic$ overlay that produces undefined

* fix(data): server-assigned IDs for creates, and one commit per server transaction (#2404)

* fix(data): server-assigned IDs for creates, and one commit per server transaction

A create can name where the server's ID is in its reply. Writes to the new
record wait for the create, are sent with the server's ID, and are refused
unsent if the create is refused. Every view a reply or an optimistic edit
changes is recomputed before any reader is notified.

* fix(data): keep a created record's writes in order across its new ID, and end them on retire

* fix(codemod): ignore erased references in SVG ownership checks (#2406)

* fix: remove the website's remaining client descriptors (#2405)

* feat(strong): reject markup outside template output

Strong mode now reports OCTANE_STRONG_VALUE_JSX for JSX returned from a
function, assigned, passed as a prop or argument, or chosen by an
expression, and for @{} blocks stored in objects or chosen by an
expression: each builds an element descriptor. The website, devtools tabs,
and compiled Router document no longer build descriptors on the client.

ErrorBoundary renders a fallback={@{ ... }} body instead of calling it as a
render prop, and the codemod lowers plain-reference && guards in Strong
output to @if/@else.

Refs #2059

* revert(strong): allow value JSX again; keep the ErrorBoundary and document fixes

Value JSX already compiles to a template behind an 'r:' record, so Strong
keeps accepting it. This drops OCTANE_STRONG_VALUE_JSX, the codemod guard
lowering, and the test conversions it required.

Kept: ErrorBoundary renders a fallback={@{ ... }} body instead of calling it,
the compiled Router document leaves server-only html/head/body out of client
builds, DevtoolsDemo's Suspense fallbacks are render bodies, and an MDX page
no longer nests a <p> inside a <p>.

* test(data): compare cached responses with a normalized worker store (#2408)

* test(data): compare cached responses with a normalized worker store on library journeys

Runs four library journeys and a cold start from storage against octane/data
as merged and a prototype normalized store that evaluates declared views in
a worker. Measures views shown, bytes fetched and persisted, worker traffic,
impossible states and feature code, as promised on #2362.

* test(data): add a normalized design that loads view windows instead of every book

* test(data): refuse journey 3's star by book ID, so the rename cannot let it through

* fix(codemod): report bare SVG issuer changes in ordinary components (#2407)

* fix(codemod): report bare SVG issuer changes in ordinary components

* fix(codemod): trace bare SVGs selected by component fallbacks

* fix(codemod): check SVG defaults on local destructuring

* fix(codemod): exclude SVG defaults overridden by an inline object

* fix(tanstack-router): keep the server document out of browser builds (#2409)

* fix(tanstack-router): keep the server document out of browser builds

The compiled Html, Head, and Body read their server-only document
components through #server-document, which resolves to a null stub under
the browser condition. Folding isServer already removed those components
from client chunks, but Rolldown had linked their createScopedElement
import first and kept it exported from the runtime chunk.

Refs #2059

* test(tanstack-router): classify the server document resolution test

* feat(codemod): migrate path SVGs with conditional clsx tokens (#2411)

* feat(data): read the store as native Octane signal reads (#2410)

* feat(data): read the store as native Octane signal reads

The Octane binding reports each store read to the renderer as a native read
source, so components subscribe as they do to signal$ and query$ and need no
hook slot. The store calls its transport after the synchronous work that
started a load, so a read during render never runs it inside the render.

* fix(data): deliver store changes to Octane readers outside the transition

Native-read notifications honored the ambient transition, so a write inside
startTransition queued its optimistic edit behind the transition. runUrgent
clears the transition context around the notification, as
useSyncExternalStore's scheduleUrgentRender does.

* feat(codemod): migrate static SVG groups and rectangles (#2412)

* feat(data): declared lists with view() (#2413)

* feat(data): declared lists with view()

A view defines a list by a rule over an entity. It loads its window plus a
margin, shares records with every other view of the entity, and evaluates its
rule locally, so an edit moves a record into, out of or across every view in
the task that made it. A write can name its saved record with `record`, which
views take in place of reloading. The Shelf example moves onto views.

* fix(data): keep paged views within max and wait for edits before reloading short windows

A later page took a left margin on top of a full window, so a page at the
view's max was refused; the margins now give way to the cap. A window that
unconfirmed edits left short reloaded on every new span until they settled;
it now reloads once the server has those edits.

* feat(codemod): prove ownership of presence-tested SVG props (#2415)

* feat(data): native forms for writes (#2414)

* feat(data): native forms for writes

A write that declares `form` fields can be submitted by a plain HTML form,
which works before hydration and with JavaScript off. `useForm(write, key?)`
gives the form its attributes, hidden fields, pending state, submitted values
and field issues; once hydrated it submits through the store with the write's
optimistic edit. On the server, `forms(request)` runs a native submission and
answers 303, or returns the refusal for the page to render again, and signs
each page's forms for its account. The Shelf example's add and remove move
onto forms, with JavaScript-off and hydration journeys.

* chore(data): format forms files and refresh the example catalog

The new forms module and its tests were untracked when formatted, and the
Shelf journey added to example.json changes the generated catalog and its
e2e shard weights.

* fix(data): let go of a form that unmounted while its submission was in flight

A form handle was released only on unsubscribe while idle, so one that
unmounted mid-submission, as every removed row does, stayed in the store for
the rest of the session. It now also lets go when its submission settles with
no subscribers.

* feat(data): encrypted persistent cache with a size budget (#2416)

* feat(data): encrypted persistent cache with a size budget

A store given `persist: { storage, partition, key, budget }` saves each
read's confirmed value, and each view's confirmed rows, and starts from them
after a restart with their age kept. Values are encrypted with AES-GCM under a
key from the session, and every name the storage sees is a keyed hash, so
people sharing a browser can neither read nor list each other's values. A
value saved under another shape of its read's output schema, where the
validator describes one, or another `version`, is discarded; one that fails
validation on restore is too. Saves are coalesced per host task and the
partition is purged to its budget, expired values first and then the least
recently used, never one a mounted component shows. The budget defaults to a
size chosen by device memory, data saving and quota. `indexedDBStorage()` and
`memoryStorage()` are included. The Shelf example persists its store.

* fix(data): save reads a write carries back, and count restores as recent use

A write reply's refreshed reads were adopted but never saved, so a reload
within their freshness showed the value from before the write. A restored
value's last use reached only the next storage write, not the order purging
reads, so it could be purged before older unused values.

* feat(codemod): follow SVGs through single-read render locals (#2417)

* feat(codemod): follow SVGs through single-read render locals

* fix(codemod): preserve evaluation and early-return boundaries

* fix(data): restore values a write marked stale as stale, and never purge in-use values at startup (#2419)

* fix(data): restore values a write marked stale as stale, and never purge in-use values at startup

A write or `invalidate()` marked only the entries in memory, so a value saved
earlier and restored within its freshness showed data from before the write.
Each tag and entity name now keeps the time it was last marked, in its own
encrypted record, and each saved value the time it was saved and the names it
holds; a value marked after it was saved is restored stale.

The startup purge ran before any component had asked for a value, so it could
delete values mounted components were about to restore. It now removes only
expired values; the budget applies from the first save.

* fix(data): save invalidation marks again after a failed save

The marks were flagged saved before the write finished and a failed write was
ignored, so its invalidations were lost and a later restart could show a value
from before the write as fresh. A failed save now leaves them flagged, and the
next save writes them.

* feat(codemod): migrate SVG classes from CSS Modules (#2420)

* feat(data): durable writes that survive a restart (#2422)

* feat(data): durable writes that survive a restart

Writes listed in `persist.journal` are saved to an encrypted journal, in the
cache's storage, before they are sent, and leave it once their outcome is
known. After a restart the store shows each journaled write's edit again and
reads the journal's `receipt` with its operation ID: an applied receipt keeps
the edit, any other rolls it back, and the write is never sent twice. A write
whose receipt cannot be read stays for the next start; one this build no
longer declares, or whose input it no longer accepts, is dropped. `retire()`
clears the journal. The Shelf example's writes are durable.

* fix(data): recover journaled writes in submission order, and retry failed removals

Storage lists the journal by hashed name, so recovered writes came back in an
arbitrary order and a later edit could lose to an earlier one. Each entry now
carries its submission order and recovery sorts by it. A failed removal from
the journal was dropped, so a settled write could come back after the next
start; it is now tried again at the next save.

* fix(codemod): defer mutable SVG clsx guards (#2423)

* fix(codemod): defer mutable SVG clsx guards

* perf(codemod): reuse fixed SVG parameter proofs

* feat(data): server-ordered reads share records with views (#2424)

* feat(data): server-ordered reads share records with views

A read that selects entities but only the server can order, such as search
results, keeps the order and membership it was sent but now shares records
with the views. Its load gives views any newer copy of a record they hold,
and it shows any copy newer than its own load, from a view, another read or a
write's `record`. A load notifies every read sharing its entities. Copies are
compared by field, and an unchanged projection keeps its identity, so a read
whose shared records did not change keeps its snapshot, even with an edit
pending.

* fix(data): share only records views hold, and tell views and the cache when a read shares one

A server-ordered read inserted every record it carried into the shared table,
so a late one could put back a record a view had since dropped; it now only
updates records the table holds. Reads a write's reply carried back now
notify every read sharing their entities, as a load does. And a read that
gives views a newer copy marks those views for saving.

* feat(codemod): pass workspace stores to deferred local helpers (#2425)

* feat(codemod): pass workspace stores to deferred local helpers

* fix(codemod): prove the native click output owner

* perf(data): read the store through useSyncExternalStore on the client again (#2429)

The client binding reported each store read to the renderer as a native signal
read. Measured against useSyncExternalStore on the same production app, with
identical renders and DOM, the native path was slower in every step large
enough to measure, and importing it turned on read collection around every
component's render, including ones that read no data. Both bindings now read
snapshots through useSyncExternalStore, as React does; the client entry is
about 3 KB gzipped smaller.

* feat(codemod): migrate native submit event annotations (#2426)

* feat(codemod): migrate native submit event annotations

* fix(codemod): verify forwarded submit event callbacks

* fix(codemod): isolate submit exports and callback slots

* fix(codemod): resolve contextual submit event types

* fix(codemod): keep deferred React submit import types

* fix(codemod): verify workspace store helper dependencies (#2430)

* fix(codemod): verify workspace store helper dependencies

* fix(codemod): trace runtime class bases in store helpers

* test(data): stabilize persistence cache assertions (#2431)

* feat(codemod): preserve explicit effect restart triggers (#2427)

* fix(codemod): trace Intl props through native forwarding wrappers (#2433)

* fix(codemod): preserve inline React Intl substitutions (#2432)

* feat(data): serve a store through a module server function (#2434)

* feat(react): support inline ReactCompat hosts (#2436)

* feat(codemod): lower JSX lists over dense array literals (#2435)

* feat(codemod): lower JSX lists over dense array literals

* fix(codemod): recognize type-wrapped dense iterables

* feat(app-core): serve module server functions from a custom server; Shelf over RPC with Vite and Rspack (#2440)

* feat(app-core): serve module server functions from a custom server; Shelf over RPC with Vite and Rspack

* fix(shelf): keep each Rspack compiler's output apart; pass Vite's own requests through untouched

* feat(data): publish, forget, awaitable retire and opaque cache keys (#2443)

* feat(data): publish, forget, awaitable retire and opaque cache keys (#2439)

* fix(data): let reads join a publish, and keep the saved copy when one is refused

* fix(codemod): defer opaque scoped store inputs (#2428)

* feat(codemod): trace scoped store factory wrappers

* fix(codemod): defer opaque scoped store inputs

* fix(codemod): keep opaque origins through imports and type wrappers

---------

Co-authored-by: Dominic Gannaway <[email protected]>

* feat(floating-ui): add standalone positioning entry (#2438)

* feat(floating-ui): add standalone positioning entry

* fix(floating-ui): classify positioning-only parity tests

* feat(codemod): migrate provider-owned React Intl locales (#2442)

* feat(codemod): migrate destructured React Intl locales

* fix(codemod): prove ownership of destructured Intl locales

* perf(data): evaluate each view from an index of the records its window holds (#2446)

* fix(codemod): migrate expression-bodied effects with explicit dependencies (#2445)

* test(codemod): retain diagnostics for opaque React Intl service calls (#2437)

* feat(codemod): preserve deferred React Intl service values

* fix(codemod): accept discarded deferred Intl service calls

---------

Co-authored-by: Dominic Gannaway <[email protected]>

* fix(codemod): preserve key evaluation in guarded list rows (#2447)

* feat(data): page views with more, pages() and usePages() (#2449)

* feat(data): page views with more, pages() and usePages()

* fix(data): keep later pages shown while an expired earlier page reloads

* fix(data): retry a failed earlier page from loadMore, and stop reporting it as refreshing

* fix(codemod): preserve property triggers in explicit effect dependencies (#2450)

* fix(codemod): preserve setup before keyed map rows (#2453)

* fix(codemod): preserve setup before keyed map rows

* fix(codemod): recognize inert primitive row keys

* fix(compiler): share keyed row destructuring with the row body (#2455)

* fix(compiler): share keyed row destructuring with the row body

* fix(compiler): preserve const row bindings in SSR keys

* test(compiler): expect one SSR row default evaluation

* fix(compiler): retain keyed text rows across equivalent bindings

* fix(codemod): enable React adapters on Octane 0.17 (#2468)

* fix(radix): project Slottable children without duplicating the host (#2473)

* fix(octane): preserve resource hints in React-hosted renders (#2490)

* fix(codemod): migrate React DOM root types (#2483)

* fix(codemod): migrate generic React event handlers (#2487)

* fix(codemod): preserve literal SVG data attributes (#2461)

* feat(octane): support a document body portal target (#2467)

* fix(octane): preserve universal imperative handle refs (#2471)

* fix(octane): preserve universal imperative handle refs

* test(drei): keep the PivotControls observer ref stable

* test(drei): refresh PivotControls parity evidence

* fix(compiler): preserve mapped JSX row keys (#2459)

* fix(compiler): preserve mapped JSX row keys

* fix(compiler): keep proven mapped tags on the native path

* fix(compiler): evaluate keys in empty mapped SSR rows (#2460)

* fix(codemod): migrate effect-only lazy mount records (#2463)

* feat(app-core): route seeds and a config data module for Vite and Rsbuild (#2492)

* feat(app-core): route seeds and a config data module for Vite and Rsbuild

* fix(app-core): cancel a live route stream on request error, and never hydrate a data root as void

* fix(codemod): preserve conditional input identity (#2503)

* fix(codemod): preserve literal SVG root overrides (#2501)

* fix(codemod): allow type queries on store consumers (#2495)

* fix(codemod): preserve the React ref allocator (#2488)

* fix(codemod): migrate standalone Floating UI positioning (#2475)

* fix(codemod): detect escaped eval in scoped store consumers (#2478)

* fix(compiler): preserve effectful JSX map callback order (#2474)

* fix(codemod): preserve authored inline React boundaries (#2479)

* feat(octane): capture initial render values in Strong mode (#2482)

* feat(octane): capture initial render values in Strong mode

* fix(compiler): preserve existing layout snapshot edits

* fix(release): separate Octane and Lynx snapshot changesets

* fix(compiler): preserve eager inputs to initial render snapshots

* test(codemod): assert eager snapshot repair during fallback

* test(cli): verify eager snapshot suggestions

* fix(codemod): prove React Intl locale ownership (#2477)

* fix(codemod): trace immutable store handle aliases (#2485)

* fix(codemod): preserve fresh imperative handles (#2499)

* fix(codemod): preserve fresh imperative handles

* fix(codemod): defer redeclared handle methods

* fix(codemod): preserve imperative handle receiver dependencies (#2470)

* fix(codemod): keep automatic React islands inside paragraphs (#2480)

* fix(codemod): preserve authored inline React boundaries

* fix(codemod): keep automatic React islands inside paragraphs

* fix(codemod): recognize published inline React host exports

* fix(codemod): keep conditional React islands inside paragraphs

* fix(codemod): follow imported fragments to paragraph hosts

* fix(codemod): adapt consolidated Radix Slot exports (#2472)

* fix(codemod): adapt consolidated Radix Slot exports

* fix(codemod): preserve local aliases that shadow Radix

* fix(codemod): preserve local Radix Slot import names

* fix(codemod): preserve SVG opacity and conditional classes (#2500)

* fix(octane): separate rewritten initial-value binding (#2505)

* fix(codemod): preserve SVG inline transforms (#2504)

* fix(codemod): preserve SVG inline transforms

* fix(codemod): recognize prior generated SVG helper

* feat(data): realtime feeds that keep loaded reads current (#2506)

* feat(data): realtime feeds that keep loaded reads current

Add feed() contracts, listen()/useFeed with one shared connection per feed
and parameters, and receive(store, changes). Events put or remove records,
replace a read's value, or invalidate tags. The store drops duplicate event
IDs, resumes from its cursor, and reloads what a feed covers after a gap.
createDataHandler serves feeds through handler.listen over a module server
function, read in the browser with serverListener. Shelf streams its changes
under Vite and Rspack.

Co-Authored-By: Claude <[email protected]>

* fix(data): reload a lower view window when a feed puts a record above it

Also have the Shelf feed check its history before waiting, so a write made
while a frame was being read is sent.

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(codemod): preserve fixed SVG colors (#2494)

* fix(codemod): preserve fixed SVG colors

* fix(codemod): recognize prior generated SVG helper

* fix(codemod): defer locally mutated store handles (#2493)

* fix(codemod): preserve custom and sparse JSX map dispatch (#2484)

* fix(codemod): migrate proven render-phase boolean state (#2465)

* fix(motion): support server rendering and hydration for motion hosts (#2491)

* fix(motion): support server rendering and hydration for motion hosts

* test(motion): classify the server host conformance tests

* fix(motion): preserve the initial frame during lazy feature loading

* fix(motion): release SVG frame for authored static values

* fix(codemod): preserve layout effect property dependencies (#2498)

* fix(codemod): migrate local rectangular SVG clipping (#2466)

* fix(codemod): migrate ref-only effect helpers (#2476)

* feat(codemod): migrate single-path SVG patterns (#2469)

* feat(codemod): migrate single-path SVG patterns

* fix(codemod): migrate static SVG path transforms

* fix(codemod): preserve SVG matrix transforms

* fix(codemod): report React hooks left in local helpers (#2464)

* fix(codemod): report React hooks left in local helpers

* fix(codemod): report React hooks after literal setup

* fix(codemod): defer React DOM-linked store inputs (#2486)

* fix(codemod): defer React DOM-linked store inputs

* fix(codemod): follow executable store dependencies

* fix(codemod): narrow resource hints to executable imports

* fix(codemod): preserve shared external-store hooks in native setup (#2481)

* fix(codemod): report React hooks left in local helpers

* fix(codemod): preserve shared external-store hooks in native setup

* fix(codemod): ignore type-only external-store hook references

* fix(codemod): preserve external-store hooks after null refs

* fix(codemod): report unsupported native hooks after null refs

* Version Packages (#2343)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* fix(codemod): report lost SSR hints in imported state initializers (#2510)

* fix(codemod): report render-time scoped store member reads (#2513)

* fix(codemod): report unproven React Intl formatter ownership (#2515)

* fix(compiler): preserve writable branch captures (#2511)

* fix(codemod): preserve native host ref state in Strong mode (#2517)

* fix(codemod): preserve native host ref state in Strong mode

* fix(codemod): verify the binding of native ref owners

* fix(codemod): preserve opaque array map dispatch (#2512)

* fix(codemod): preserve opaque array map dispatch

* fix(examples): make Hacker News list dispatch explicit

* test(codemod): verify Hacker News fresh lists in Strong mode

* fix(codemod): report opaque effect dependency getters (#2516)

* fix(codemod): report opaque effect dependency getters

* fix(codemod): check effect getters in JSX-free templates

* fix(codemod): preserve keyed JSX row evaluation order (#2518)

* fix(codemod): preserve keyed JSX row evaluation order

* fix(codemod): preserve keyed rows with multiline JSX children

* feat(testing): add installTestClock, one host seam for runtime time (#2519)

* feat(testing): add installTestClock, one host seam for runtime time

Route the runtime's timers, animation frames, host tasks and now() through
host-task.ts so one installed clock decides their order. octane/testing's
installTestClock() owns that clock: advance(ms), frame() and settle() move
it; act() runs work that is already due without moving time; uninstall()
hands held work back to the host. Converts the flaky ViewTransition
pre-render passive test from half-faked timers to the clock.

Phase 1 of #2508.

Co-Authored-By: Claude <[email protected]>

* fix(testing): keep host-task DOM-free and create the post-paint channel eagerly

host-task.ts is part of DOM-free programs (ink, opentui), so read
requestAnimationFrame and document through a typed globalThis instead of
naming DOM globals. Restore creating the post-paint MessageChannel when
passive work is scheduled, as lazy-client-initialization pins, rather
than inside the frame callback.

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(compiler): type generated child traversal on opaque DOM hosts (#2520)

* fix(codemod): retain async and generator map results (#2521)

* fix(codemod): keep retained maps renderable in directive arms (#2522)

* fix(codemod): report generated Intl formatter ownership (#2523)

* fix(octane): preserve type imports in the native TypeScript parser (#2525)

* feat(compiler): hint Strong reads of state after its own setter (#2526)

* feat(compiler): hint Strong reads of state after its own setter

* fix(compiler): scope read-after-set updates per switch case; list recipe in Strong skill

* feat(data): WebSocket and broker feed listeners, and feed cursors across restarts (#2524)

* feat(data): WebSocket and broker feed listeners, and feed cursors across restarts

webSocketListener streams feeds over a socket that handler.accept serves
with no time limit, refusing other origins. pubSubListener listens through a
broker the page already uses. A persistent store saves each feed's cursor
with its stale marks, so the next session replays what it missed, and an
event marks saved copies it could not reach in memory stale.

Co-Authored-By: Claude <[email protected]>

* fix(data): back off a WebSocket feed the server closes with an error

A browser calls any completed close handshake clean, so a refused (1008) or
failed (1011) socket reconnected at once. Only a normal close now ends a
connection without an error, and with Octane's protocol a socket counts as
live once accept has read its request.

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* chore(changeset): release installTestClock and data feed listeners as patches (#2527)

* chore(changeset): release installTestClock as a patch

* chore(changeset): release data feed listeners as a patch

* feat(testing): put data, hydration and signals timing on the test clock (#2529)

Phase 2 of #2508. Route octane/data freshness, retention, persistence
stamps and feed backoff, idle and streamed hydration timers, deferred
event fallbacks, signal action timeouts, resize-observer delivery and the
universal re-settle retry through host-task.ts. Add hostDateNow() and
TestClock.dateNow() so data freshness follows the clock, and let the
clock respect a hidden page. Convert transition-timeout and effect-timing
off Vitest fake timers, run the data freshness test on the clock, and add
an idle-hydration clock test.

Co-authored-by: Claude <[email protected]>

* feat(data): carry feed positions in a server render's seed (#2530)

* feat(data): carry feed positions in a server render's seed

A store with no listen asks each feed in its new feeds option for its
position before its first read, and its seed carries them, so the browser's
feed resumes from before the page's values loaded. The data handler answers
a position request with the first cursor the feed's handler yields when it
starts with none.

Co-Authored-By: Claude <[email protected]>

* fix(data): stop a server render's feed position request when its store retires

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(octane): suspend a list of suspending rows once, not once per row (#2528)

* fix(octane): suspend a list of suspending rows once, not once per row

Co-Authored-By: Claude <[email protected]>

* fix(octane): pace rejected row thenables and fold row deferral without suspension

Co-Authored-By: Claude <[email protected]>

* perf(octane): keep row suspension collection out of bundles that cannot suspend

Co-Authored-By: Claude <[email protected]>

* test(octane): pin row-ordered request starts for suspending keyed lists

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(compiler): suggest useInitialValue for nested readonly bindings (#2533)

* fix(codemod): preserve eager prop reads in state initializers (#2536)

* fix(codemod): move effect-only ref helpers into their effect (#2535)

* fix(codemod): guard escaped scoped-store handles (#2537)

* fix(codemod): respect nested React Intl export conditions (#2538)

* fix(codemod): resolve effect restart triggers by binding (#2539)

* fix(compiler): diagnose state updates through bound effect schedulers (#2544)

* fix(codemod): report React Intl scalar formatter ownership (#2543)

* feat(testing): put server and RPC deadlines on the test clock (#2531)

* feat(testing): put server and RPC deadlines on the test clock

Part 1 of phase 3 of #2508. Route the SSR suspense deadline, the stalled
reader backoff and its deadline, streamed-signal budgets, server-function
batch and stream timeouts, the server-function client deadline and timer,
octane/data's server long-poll lifetime and the React-hosted SSR timeout
through host-task.ts. SSR's macrotask yield stays on real time: it waits
for real I/O. Convert the prerender deadline, stalled-reader deadline and
RPC client deadline tests to the clock.

Co-Authored-By: Claude <[email protected]>

* fix(testing): keep TestClock.dateNow() in whole milliseconds

The clock's time starts at performance.now() and frame() snaps to 16 ms
boundaries, so dateNow() could be fractional. Date.now() never is, and
callers rely on that: the server-function client passed a fractional
leftover deadline to serverResultLimits, which requires an integer, and
threw a RangeError. Floor the clock's date, as Date.now() would be.

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(radix): ignore deferred outside presses on registered branches (#2534)

* test(tanstack-virtual): render the SSR hydration fixture in beforeAll (#2550)

* test(tanstack-virtual): render the SSR hydration fixture in beforeAll

The test body started a cold Vite SSR server and compiled the whole server
runtime before hydrating. That setup is ~0.5 s idle and 2.2-2.7 s on the
loaded React parity shard 2/4, with a tail past the 5 s test budget; the
hydration under test takes ~20 ms. Render the server twin in beforeAll, as
the input-otp and alien-signals hydration suites already do.

* test(tanstack-virtual): refresh the ssr-hydration parity evidence hash

* fix(data): preserve ambiguous writes and fence dispatch after retirement (#2540)

* fix(data): preserve ambiguous writes and fence dispatch after retirement

* test(data): narrow the uncertain write before settling it

* test(data): wait for dispatch before retiring the test store

* fix(data): keep newer reads when write replies arrive out of order (#2541)

* fix(data): keep newer reads when write replies arrive out of order

* fix(data): reuse a matching feed reply and reconcile a partial update

* test(data): cover deletions outside the current read and view

* fix(data): preserve confirmed SSR snapshots and lazy seed age (#2546)

* fix(data): preserve confirmed SSR snapshots and lazy seed age

* refactor(data): keep serialized seed entries uniform

* fix(codemod): migrate scoped-store uses in Effect Events (#2552)

* fix(codemod): migrate render latches initialized from boolean props (#2551)

* fix(data): preserve native form retry identity and retire held forms (#2547)

* fix(data): preserve native form retry identity and retire held forms

* fix(data): preserve native form retry identity and retire held forms

* fix(data): keep mounted form hooks idle after retirement

* test(data): cancel native submit on a retired mounted form

* fix(data): discard frames after a feed disconnects (#2545)

* fix(data): discard frames after a feed disconnects

* docs(data): explain retirement at the feed delivery boundary

* fix(codemod): protect React island source modules before writing (#2554)

* fix(codemod): protect React island source modules before writing

* fix(codemod): follow logical React island component values

* fix(data): preserve recovery state until cache updates are durable (#2542)

* fix(data): preserve recovery state until cache updates are durable

* fix(data): reconcile obsolete journal entries and retry a failed flush

* fix(data): retain prepared cache values across storage retries

* fix(data): preserve wire input identity and rejoin evicted reads (#2548)

* fix(data): preserve wire input identity and rejoin evicted reads

* fix(data): preserve wire input identity and rejoin evicted reads

* test(effect-atom): wait for scheduled task completion (#2553)

* test(effect-atom): wait for scheduled task completion

* test(effect-atom): refresh scheduled-task parity evidence

* fix(codemod): recover shorthand types for stable scalar props (#2555)

* fix(codemod): recover shorthand types for stable scalar props

* fix(codemod): defer shorthand recovery for unresolved value imports

* fix(codemod): check imported JSX before migrating scoped-store arguments (#2556)

* fix(codemod): check imported JSX before migrating scoped-store arguments

* fix(codemod): resolve the value of merged scoped-store exports

* fix(data): reconcile persisted and server-rendered feed cursors (#2549)

* fix(data): reconcile persisted and server-rendered feed cursors

* fix(data): reconcile persisted and server-rendered feed cursors

* fix(data): persist the reconciled cursor on idle streams

* feat(data): one owner for several replica stores over message ports (#2559)

* feat(data): one owner for several replica stores over message ports

Co-Authored-By: Claude <[email protected]>

* fix(data): reloads never join an older shared read; followed creates gate edits

A replica asking again for a read it already asked for is reloading, so the
owner starts a new request rather than answering it with one that may predate
the change, and only the newest read for a key shares its value. A replica
following another tab's create now holds that record's queue behind its
outcome, as the sending tab does.

Co-Authored-By: Claude <[email protected]>

* fix(data): a replica recognises a view's reload by its wire key

Co-Authored-By: Claude <[email protected]>

* fix(data): only reads count toward a replica's reload record

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* feat(mcp-server): agent driver that drives an Octane app on the test clock (#2558)

* feat(mcp-server): agent driver that drives an Octane app on the test clock

Adds the octane/agent entry, which installs the test clock ahead of the app's scripts, and nine octane_app_* MCP tools that drive one page of a Vite dev server in Chromium (#2508 phase 3).

* style(mcp-server): format agent driver files

* fix(mcp-server): serve the agent module under Vite's base

* fix(codemod): retain installed data descriptors in scoped-store effects (#2561)

* fix(codemod): trace scoped-store JSX through wildcard exports (#2562)

* fix(codemod): check React hook dependency getters (#2563)

* feat(data): share one owner between tabs through a SharedWorker (#2560)

* feat(data): share one owner between tabs through a SharedWorker

Co-Authored-By: Claude <[email protected]>

* fix(examples): declare the shared-owner journey in Shelf's example.json

Co-Authored-By: Claude <[email protected]>

* test(compiler): count emitFile chunk records as bundler records in the AST emit audit

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(codemod): keep deferred store field ownership diagnostics (#2566)

* fix(codemod): flag destructured bare SVG components (#2564)

* fix(codemod): flag destructured bare SVG components

* fix(codemod): check the final selected SVG record field

* fix(codemod): trace render-time scoped-store results (#2565)

* fix(codemod): report SSR hints called by inline state initializers (#2568)

* test(swr): isolate the pristine retry callback clock (#2570)

* feat(codemod): migrate static SVG circles and root data (#2571)

* fix(octane): dispatch custom JSX map before receiver checks (#2569)

* fix(codemod): check conditional hook dependency getters (#2573)

* fix(codemod): report generated Intl formatter ownership (#2574)

* fix(codemod): report generated Intl formatter ownership

* test(codemod): preserve Intl upgrade ownership findings

* feat(data): fence shared owners by the origin's signed-in account (#2572)

* feat(data): fence shared owners by the origin's signed-in account

Co-Authored-By: Claude <[email protected]>

* fix(data): bump the owner protocol for hello, and retry a failed account record

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* feat(codemod): preserve fresh inline imperative handles (#2576)

* fix(codemod): report unchanged React context hooks (#2577)

* fix(codemod): report ownership for all scalar Intl formatters (#2579)

* fix(vite-plugin): forward dataWorker to the compiler plugin (#2578)

* docs(data): document octane/data across the website, llms.txt, MCP and READMEs (#2575)

* docs(data): add the octane/data guide, reference, and llms/MCP coverage

Add a website Data guide (Octane and React examples, six diagrams), a
docs/data.md reference served by the MCP server, llms.txt coverage, and
links from the READMEs, sitemap, and Signals guide. A docs test compiles
every example and checks the reference tables against real exports.

* fix(data): typecheck persist.key under bun-types

bun-types declares CryptoKey so it survives a typeof function check. The
website program loads bun-types and now type-checks octane/data through
the new docs test, which failed on persist.ts.

* docs(data): document account fencing for shared owners (#2572)

* docs(data): give each sequence diagram step its own grid row

Auto-placement could put a later step beside an earlier one; an explicit
row keeps the numbered messages reading top to bottom.

* fix(compiler): allow data maps with unreachable JSX (#2581)

* fix(compiler): preserve JSX map addition order (#2582)

* fix(compiler): preserve JSX map conversion order (#2585)

* fix(website): preserve playground AST pins during startup (#2584)

* feat(data): shared tabs fall back to their own store, and survive other builds and crashes (#2583)

* feat(data): shared tabs fall back to their own store, and survive other builds and crashes

Co-Authored-By: Claude <[email protected]>

* fix(data): serve a tab again when it wakes after being dropped, and count unanswered pings

A silent tab is dropped from feeds but served again if it speaks under the same
generation. A tab detects a lost owner after three unanswered pings rather than
wall-clock silence, so throttled background timers never cause a reconnect, and
pauses its heartbeat while frozen. Format data.mdx.

Co-Authored-By: Claude <[email protected]>

* fix(data): restart the owner's sweep when a dropped tab is served again

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix: preserve shadowed createPortal calls (#2588)

* fix: preserve shadowed createPortal calls

* fix: keep shadowed portal-spelled callbacks callable

* fix(compiler): preserve direct portal argument order

* fix: preserve shadowed template factory callbacks (#2591)

* fix(codemod): report nested React islands in hosted SSR (#2590)

* fix(codemod): report nested React islands in hosted SSR

* fix(codemod): check paired OctaneCompat tags

* fix(codemod): inspect default JSX exports in SSR hosts

* chore(changeset): release recent features as patches (#2601)

* fix(compiler): preserve optional body portal SSR

* fix(codemod): verify the final Strong repair (#2595)

* fix(codemod): diagnose SVG namespace default tags (#2598)

* fix(compiler): preserve asserted portal operand evaluation

* feat(data): read one way, with useRead(store.read(...)) (#2600)

* feat(data): read one way: useRead(store.read(...)), with { suspend: false } for the snapshot

Co-Authored-By: Claude <[email protected]>

* test: read data through useRead(store.read(...)) in the plugin fixtures; patch changeset

Co-Authored-By: Claude <[email protected]>

* feat(data): drop useWrite; components write with useDataStore().write(...)

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(codemod): report unchanged React root components (#2604)

* feat(data): the shared owner is the only writer of an account's cache and journal (#2594)

* feat(data): the shared owner is the only writer of an account's cache and journal

Co-Authored-By: Claude <[email protected]>

* fix(data): a tab with no owner uses its own cache; protocol 4; sign-out answers recover with no entries

Co-Authored-By: Claude <[email protected]>

* chore: release the shared cache as a patch

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(codemod): report retained React callback hooks (#2607)

* fix(compiler): evaluate parent props before a render retry (#2603)

* fix(compiler): evaluate parent props before a render retry

* fix(compiler): recognize type-only wrappers on retry operands

---------

Co-authored-by: Dominic Gannaway <[email protected]>
Co-authored-by: Claude <[email protected]>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
domgan-oai added a commit that referenced this pull request Nov 13, 2026
* feat: let packages declare Strong mode and applications require it (#2400)

* feat: let packages declare Strong mode and applications require it

Packages declare Strong in package.json with "octane": { "strong": true }
or a list of paths. compiler.strongDependencies: { require, allow } fails the
build with OCTANE_STRONG_DEPENDENCY when an application module reaches a
non-Strong module in another Octane package or an octane/react boundary. The
walk moves from the CLI into the compiler, so octane analyze previews exactly
what the build rejects.

The six packages the website renders declare their Strong modules, and the
website turns require on with an empty allow list. Its playground version
picker replaces @octanejs/base-ui's Combobox with a local listbox.

Refs #2059

Co-Authored-By: Claude <[email protected]>

* fix: address review on Strong dependency requirement

- Vite plugin: always read octane.config.ts, so strongDependencies is not
  dropped when strong and renderers are both passed inline.
- octane analyze: keep going under require when there are no views, so plain
  application modules are still checked.
- Playground version picker: keep focus in the input on any press inside the
  list, not only on option rows.

Co-Authored-By: Claude <[email protected]>

* fix(website): let the version list's scrollbar scroll

A mousedown preventDefault on the scrolling list also blocked its scrollbar.
The list now takes focus itself (tabIndex -1), and the field closes the popup
only when focus leaves it. Choosing an option returns focus to the input.

Co-Authored-By: Claude <[email protected]>

* fix(website): close the version list through the bubbling onBlur

Octane's onBlur is delegated as focusout, as React's is, and it is the
typed name; onFocusOut is not.

Co-Authored-By: Claude <[email protected]>

* fix(website): return focus to the version input on Escape

The list can hold focus, so hiding it on Escape dropped focus to the page.

Co-Authored-By: Claude <[email protected]>

* fix(compiler): name the Strong dependency code in its message

The printed-code audit rejects interpolating a non-diagnostic `.code`.

Co-Authored-By: Claude <[email protected]>

* test(website): expect the package reason in Strong module status

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* feat(codemod): migrate verified path-only SVG components (#2398)

* fix(codemod): trace SVGs through native renderable props (#2402)

* feat(codemod): migrate verified path-only SVG components

* fix(codemod): trace SVGs through native renderable props

* fix(codemod): follow proven renderable TypeScript wrappers

* fix(signals): replay optimistic$ updaters over newer source values (#2401)

* fix(signals): replay optimistic$ updaters over newer source values

An overlay kept the value its updater produced at write time, so a refetch,
stream value or direct write stayed hidden behind a pending edit, and a
rejected operation's edit survived inside a later operation's value. Keep
each operation's writes and replay them in order over the current source,
as useOptimistic rebases its updates.

* fix(signals): show an optimistic$ overlay that produces undefined

* fix(data): server-assigned IDs for creates, and one commit per server transaction (#2404)

* fix(data): server-assigned IDs for creates, and one commit per server transaction

A create can name where the server's ID is in its reply. Writes to the new
record wait for the create, are sent with the server's ID, and are refused
unsent if the create is refused. Every view a reply or an optimistic edit
changes is recomputed before any reader is notified.

* fix(data): keep a created record's writes in order across its new ID, and end them on retire

* fix(codemod): ignore erased references in SVG ownership checks (#2406)

* fix: remove the website's remaining client descriptors (#2405)

* feat(strong): reject markup outside template output

Strong mode now reports OCTANE_STRONG_VALUE_JSX for JSX returned from a
function, assigned, passed as a prop or argument, or chosen by an
expression, and for @{} blocks stored in objects or chosen by an
expression: each builds an element descriptor. The website, devtools tabs,
and compiled Router document no longer build descriptors on the client.

ErrorBoundary renders a fallback={@{ ... }} body instead of calling it as a
render prop, and the codemod lowers plain-reference && guards in Strong
output to @if/@else.

Refs #2059

* revert(strong): allow value JSX again; keep the ErrorBoundary and document fixes

Value JSX already compiles to a template behind an 'r:' record, so Strong
keeps accepting it. This drops OCTANE_STRONG_VALUE_JSX, the codemod guard
lowering, and the test conversions it required.

Kept: ErrorBoundary renders a fallback={@{ ... }} body instead of calling it,
the compiled Router document leaves server-only html/head/body out of client
builds, DevtoolsDemo's Suspense fallbacks are render bodies, and an MDX page
no longer nests a <p> inside a <p>.

* test(data): compare cached responses with a normalized worker store (#2408)

* test(data): compare cached responses with a normalized worker store on library journeys

Runs four library journeys and a cold start from storage against octane/data
as merged and a prototype normalized store that evaluates declared views in
a worker. Measures views shown, bytes fetched and persisted, worker traffic,
impossible states and feature code, as promised on #2362.

* test(data): add a normalized design that loads view windows instead of every book

* test(data): refuse journey 3's star by book ID, so the rename cannot let it through

* fix(codemod): report bare SVG issuer changes in ordinary components (#2407)

* fix(codemod): report bare SVG issuer changes in ordinary components

* fix(codemod): trace bare SVGs selected by component fallbacks

* fix(codemod): check SVG defaults on local destructuring

* fix(codemod): exclude SVG defaults overridden by an inline object

* fix(tanstack-router): keep the server document out of browser builds (#2409)

* fix(tanstack-router): keep the server document out of browser builds

The compiled Html, Head, and Body read their server-only document
components through #server-document, which resolves to a null stub under
the browser condition. Folding isServer already removed those components
from client chunks, but Rolldown had linked their createScopedElement
import first and kept it exported from the runtime chunk.

Refs #2059

* test(tanstack-router): classify the server document resolution test

* feat(codemod): migrate path SVGs with conditional clsx tokens (#2411)

* feat(data): read the store as native Octane signal reads (#2410)

* feat(data): read the store as native Octane signal reads

The Octane binding reports each store read to the renderer as a native read
source, so components subscribe as they do to signal$ and query$ and need no
hook slot. The store calls its transport after the synchronous work that
started a load, so a read during render never runs it inside the render.

* fix(data): deliver store changes to Octane readers outside the transition

Native-read notifications honored the ambient transition, so a write inside
startTransition queued its optimistic edit behind the transition. runUrgent
clears the transition context around the notification, as
useSyncExternalStore's scheduleUrgentRender does.

* feat(codemod): migrate static SVG groups and rectangles (#2412)

* feat(data): declared lists with view() (#2413)

* feat(data): declared lists with view()

A view defines a list by a rule over an entity. It loads its window plus a
margin, shares records with every other view of the entity, and evaluates its
rule locally, so an edit moves a record into, out of or across every view in
the task that made it. A write can name its saved record with `record`, which
views take in place of reloading. The Shelf example moves onto views.

* fix(data): keep paged views within max and wait for edits before reloading short windows

A later page took a left margin on top of a full window, so a page at the
view's max was refused; the margins now give way to the cap. A window that
unconfirmed edits left short reloaded on every new span until they settled;
it now reloads once the server has those edits.

* feat(codemod): prove ownership of presence-tested SVG props (#2415)

* feat(data): native forms for writes (#2414)

* feat(data): native forms for writes

A write that declares `form` fields can be submitted by a plain HTML form,
which works before hydration and with JavaScript off. `useForm(write, key?)`
gives the form its attributes, hidden fields, pending state, submitted values
and field issues; once hydrated it submits through the store with the write's
optimistic edit. On the server, `forms(request)` runs a native submission and
answers 303, or returns the refusal for the page to render again, and signs
each page's forms for its account. The Shelf example's add and remove move
onto forms, with JavaScript-off and hydration journeys.

* chore(data): format forms files and refresh the example catalog

The new forms module and its tests were untracked when formatted, and the
Shelf journey added to example.json changes the generated catalog and its
e2e shard weights.

* fix(data): let go of a form that unmounted while its submission was in flight

A form handle was released only on unsubscribe while idle, so one that
unmounted mid-submission, as every removed row does, stayed in the store for
the rest of the session. It now also lets go when its submission settles with
no subscribers.

* feat(data): encrypted persistent cache with a size budget (#2416)

* feat(data): encrypted persistent cache with a size budget

A store given `persist: { storage, partition, key, budget }` saves each
read's confirmed value, and each view's confirmed rows, and starts from them
after a restart with their age kept. Values are encrypted with AES-GCM under a
key from the session, and every name the storage sees is a keyed hash, so
people sharing a browser can neither read nor list each other's values. A
value saved under another shape of its read's output schema, where the
validator describes one, or another `version`, is discarded; one that fails
validation on restore is too. Saves are coalesced per host task and the
partition is purged to its budget, expired values first and then the least
recently used, never one a mounted component shows. The budget defaults to a
size chosen by device memory, data saving and quota. `indexedDBStorage()` and
`memoryStorage()` are included. The Shelf example persists its store.

* fix(data): save reads a write carries back, and count restores as recent use

A write reply's refreshed reads were adopted but never saved, so a reload
within their freshness showed the value from before the write. A restored
value's last use reached only the next storage write, not the order purging
reads, so it could be purged before older unused values.

* feat(codemod): follow SVGs through single-read render locals (#2417)

* feat(codemod): follow SVGs through single-read render locals

* fix(codemod): preserve evaluation and early-return boundaries

* fix(data): restore values a write marked stale as stale, and never purge in-use values at startup (#2419)

* fix(data): restore values a write marked stale as stale, and never purge in-use values at startup

A write or `invalidate()` marked only the entries in memory, so a value saved
earlier and restored within its freshness showed data from before the write.
Each tag and entity name now keeps the time it was last marked, in its own
encrypted record, and each saved value the time it was saved and the names it
holds; a value marked after it was saved is restored stale.

The startup purge ran before any component had asked for a value, so it could
delete values mounted components were about to restore. It now removes only
expired values; the budget applies from the first save.

* fix(data): save invalidation marks again after a failed save

The marks were flagged saved before the write finished and a failed write was
ignored, so its invalidations were lost and a later restart could show a value
from before the write as fresh. A failed save now leaves them flagged, and the
next save writes them.

* feat(codemod): migrate SVG classes from CSS Modules (#2420)

* feat(data): durable writes that survive a restart (#2422)

* feat(data): durable writes that survive a restart

Writes listed in `persist.journal` are saved to an encrypted journal, in the
cache's storage, before they are sent, and leave it once their outcome is
known. After a restart the store shows each journaled write's edit again and
reads the journal's `receipt` with its operation ID: an applied receipt keeps
the edit, any other rolls it back, and the write is never sent twice. A write
whose receipt cannot be read stays for the next start; one this build no
longer declares, or whose input it no longer accepts, is dropped. `retire()`
clears the journal. The Shelf example's writes are durable.

* fix(data): recover journaled writes in submission order, and retry failed removals

Storage lists the journal by hashed name, so recovered writes came back in an
arbitrary order and a later edit could lose to an earlier one. Each entry now
carries its submission order and recovery sorts by it. A failed removal from
the journal was dropped, so a settled write could come back after the next
start; it is now tried again at the next save.

* fix(codemod): defer mutable SVG clsx guards (#2423)

* fix(codemod): defer mutable SVG clsx guards

* perf(codemod): reuse fixed SVG parameter proofs

* feat(data): server-ordered reads share records with views (#2424)

* feat(data): server-ordered reads share records with views

A read that selects entities but only the server can order, such as search
results, keeps the order and membership it was sent but now shares records
with the views. Its load gives views any newer copy of a record they hold,
and it shows any copy newer than its own load, from a view, another read or a
write's `record`. A load notifies every read sharing its entities. Copies are
compared by field, and an unchanged projection keeps its identity, so a read
whose shared records did not change keeps its snapshot, even with an edit
pending.

* fix(data): share only records views hold, and tell views and the cache when a read shares one

A server-ordered read inserted every record it carried into the shared table,
so a late one could put back a record a view had since dropped; it now only
updates records the table holds. Reads a write's reply carried back now
notify every read sharing their entities, as a load does. And a read that
gives views a newer copy marks those views for saving.

* feat(codemod): pass workspace stores to deferred local helpers (#2425)

* feat(codemod): pass workspace stores to deferred local helpers

* fix(codemod): prove the native click output owner

* perf(data): read the store through useSyncExternalStore on the client again (#2429)

The client binding reported each store read to the renderer as a native signal
read. Measured against useSyncExternalStore on the same production app, with
identical renders and DOM, the native path was slower in every step large
enough to measure, and importing it turned on read collection around every
component's render, including ones that read no data. Both bindings now read
snapshots through useSyncExternalStore, as React does; the client entry is
about 3 KB gzipped smaller.

* feat(codemod): migrate native submit event annotations (#2426)

* feat(codemod): migrate native submit event annotations

* fix(codemod): verify forwarded submit event callbacks

* fix(codemod): isolate submit exports and callback slots

* fix(codemod): resolve contextual submit event types

* fix(codemod): keep deferred React submit import types

* fix(codemod): verify workspace store helper dependencies (#2430)

* fix(codemod): verify workspace store helper dependencies

* fix(codemod): trace runtime class bases in store helpers

* test(data): stabilize persistence cache assertions (#2431)

* feat(codemod): preserve explicit effect restart triggers (#2427)

* fix(codemod): trace Intl props through native forwarding wrappers (#2433)

* fix(codemod): preserve inline React Intl substitutions (#2432)

* feat(data): serve a store through a module server function (#2434)

* feat(react): support inline ReactCompat hosts (#2436)

* feat(codemod): lower JSX lists over dense array literals (#2435)

* feat(codemod): lower JSX lists over dense array literals

* fix(codemod): recognize type-wrapped dense iterables

* feat(app-core): serve module server functions from a custom server; Shelf over RPC with Vite and Rspack (#2440)

* feat(app-core): serve module server functions from a custom server; Shelf over RPC with Vite and Rspack

* fix(shelf): keep each Rspack compiler's output apart; pass Vite's own requests through untouched

* feat(data): publish, forget, awaitable retire and opaque cache keys (#2443)

* feat(data): publish, forget, awaitable retire and opaque cache keys (#2439)

* fix(data): let reads join a publish, and keep the saved copy when one is refused

* fix(codemod): defer opaque scoped store inputs (#2428)

* feat(codemod): trace scoped store factory wrappers

* fix(codemod): defer opaque scoped store inputs

* fix(codemod): keep opaque origins through imports and type wrappers

---------

Co-authored-by: Dominic Gannaway <[email protected]>

* feat(floating-ui): add standalone positioning entry (#2438)

* feat(floating-ui): add standalone positioning entry

* fix(floating-ui): classify positioning-only parity tests

* feat(codemod): migrate provider-owned React Intl locales (#2442)

* feat(codemod): migrate destructured React Intl locales

* fix(codemod): prove ownership of destructured Intl locales

* perf(data): evaluate each view from an index of the records its window holds (#2446)

* fix(codemod): migrate expression-bodied effects with explicit dependencies (#2445)

* test(codemod): retain diagnostics for opaque React Intl service calls (#2437)

* feat(codemod): preserve deferred React Intl service values

* fix(codemod): accept discarded deferred Intl service calls

---------

Co-authored-by: Dominic Gannaway <[email protected]>

* fix(codemod): preserve key evaluation in guarded list rows (#2447)

* feat(data): page views with more, pages() and usePages() (#2449)

* feat(data): page views with more, pages() and usePages()

* fix(data): keep later pages shown while an expired earlier page reloads

* fix(data): retry a failed earlier page from loadMore, and stop reporting it as refreshing

* fix(codemod): preserve property triggers in explicit effect dependencies (#2450)

* fix(codemod): preserve setup before keyed map rows (#2453)

* fix(codemod): preserve setup before keyed map rows

* fix(codemod): recognize inert primitive row keys

* fix(compiler): share keyed row destructuring with the row body (#2455)

* fix(compiler): share keyed row destructuring with the row body

* fix(compiler): preserve const row bindings in SSR keys

* test(compiler): expect one SSR row default evaluation

* fix(compiler): retain keyed text rows across equivalent bindings

* fix(codemod): enable React adapters on Octane 0.17 (#2468)

* fix(radix): project Slottable children without duplicating the host (#2473)

* fix(octane): preserve resource hints in React-hosted renders (#2490)

* fix(codemod): migrate React DOM root types (#2483)

* fix(codemod): migrate generic React event handlers (#2487)

* fix(codemod): preserve literal SVG data attributes (#2461)

* feat(octane): support a document body portal target (#2467)

* fix(octane): preserve universal imperative handle refs (#2471)

* fix(octane): preserve universal imperative handle refs

* test(drei): keep the PivotControls observer ref stable

* test(drei): refresh PivotControls parity evidence

* fix(compiler): preserve mapped JSX row keys (#2459)

* fix(compiler): preserve mapped JSX row keys

* fix(compiler): keep proven mapped tags on the native path

* fix(compiler): evaluate keys in empty mapped SSR rows (#2460)

* fix(codemod): migrate effect-only lazy mount records (#2463)

* feat(app-core): route seeds and a config data module for Vite and Rsbuild (#2492)

* feat(app-core): route seeds and a config data module for Vite and Rsbuild

* fix(app-core): cancel a live route stream on request error, and never hydrate a data root as void

* fix(codemod): preserve conditional input identity (#2503)

* fix(codemod): preserve literal SVG root overrides (#2501)

* fix(codemod): allow type queries on store consumers (#2495)

* fix(codemod): preserve the React ref allocator (#2488)

* fix(codemod): migrate standalone Floating UI positioning (#2475)

* fix(codemod): detect escaped eval in scoped store consumers (#2478)

* fix(compiler): preserve effectful JSX map callback order (#2474)

* fix(codemod): preserve authored inline React boundaries (#2479)

* feat(octane): capture initial render values in Strong mode (#2482)

* feat(octane): capture initial render values in Strong mode

* fix(compiler): preserve existing layout snapshot edits

* fix(release): separate Octane and Lynx snapshot changesets

* fix(compiler): preserve eager inputs to initial render snapshots

* test(codemod): assert eager snapshot repair during fallback

* test(cli): verify eager snapshot suggestions

* fix(codemod): prove React Intl locale ownership (#2477)

* fix(codemod): trace immutable store handle aliases (#2485)

* fix(codemod): preserve fresh imperative handles (#2499)

* fix(codemod): preserve fresh imperative handles

* fix(codemod): defer redeclared handle methods

* fix(codemod): preserve imperative handle receiver dependencies (#2470)

* fix(codemod): keep automatic React islands inside paragraphs (#2480)

* fix(codemod): preserve authored inline React boundaries

* fix(codemod): keep automatic React islands inside paragraphs

* fix(codemod): recognize published inline React host exports

* fix(codemod): keep conditional React islands inside paragraphs

* fix(codemod): follow imported fragments to paragraph hosts

* fix(codemod): adapt consolidated Radix Slot exports (#2472)

* fix(codemod): adapt consolidated Radix Slot exports

* fix(codemod): preserve local aliases that shadow Radix

* fix(codemod): preserve local Radix Slot import names

* fix(codemod): preserve SVG opacity and conditional classes (#2500)

* fix(octane): separate rewritten initial-value binding (#2505)

* fix(codemod): preserve SVG inline transforms (#2504)

* fix(codemod): preserve SVG inline transforms

* fix(codemod): recognize prior generated SVG helper

* feat(data): realtime feeds that keep loaded reads current (#2506)

* feat(data): realtime feeds that keep loaded reads current

Add feed() contracts, listen()/useFeed with one shared connection per feed
and parameters, and receive(store, changes). Events put or remove records,
replace a read's value, or invalidate tags. The store drops duplicate event
IDs, resumes from its cursor, and reloads what a feed covers after a gap.
createDataHandler serves feeds through handler.listen over a module server
function, read in the browser with serverListener. Shelf streams its changes
under Vite and Rspack.

Co-Authored-By: Claude <[email protected]>

* fix(data): reload a lower view window when a feed puts a record above it

Also have the Shelf feed check its history before waiting, so a write made
while a frame was being read is sent.

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(codemod): preserve fixed SVG colors (#2494)

* fix(codemod): preserve fixed SVG colors

* fix(codemod): recognize prior generated SVG helper

* fix(codemod): defer locally mutated store handles (#2493)

* fix(codemod): preserve custom and sparse JSX map dispatch (#2484)

* fix(codemod): migrate proven render-phase boolean state (#2465)

* fix(motion): support server rendering and hydration for motion hosts (#2491)

* fix(motion): support server rendering and hydration for motion hosts

* test(motion): classify the server host conformance tests

* fix(motion): preserve the initial frame during lazy feature loading

* fix(motion): release SVG frame for authored static values

* fix(codemod): preserve layout effect property dependencies (#2498)

* fix(codemod): migrate local rectangular SVG clipping (#2466)

* fix(codemod): migrate ref-only effect helpers (#2476)

* feat(codemod): migrate single-path SVG patterns (#2469)

* feat(codemod): migrate single-path SVG patterns

* fix(codemod): migrate static SVG path transforms

* fix(codemod): preserve SVG matrix transforms

* fix(codemod): report React hooks left in local helpers (#2464)

* fix(codemod): report React hooks left in local helpers

* fix(codemod): report React hooks after literal setup

* fix(codemod): defer React DOM-linked store inputs (#2486)

* fix(codemod): defer React DOM-linked store inputs

* fix(codemod): follow executable store dependencies

* fix(codemod): narrow resource hints to executable imports

* fix(codemod): preserve shared external-store hooks in native setup (#2481)

* fix(codemod): report React hooks left in local helpers

* fix(codemod): preserve shared external-store hooks in native setup

* fix(codemod): ignore type-only external-store hook references

* fix(codemod): preserve external-store hooks after null refs

* fix(codemod): report unsupported native hooks after null refs

* Version Packages (#2343)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* fix(codemod): report lost SSR hints in imported state initializers (#2510)

* fix(codemod): report render-time scoped store member reads (#2513)

* fix(codemod): report unproven React Intl formatter ownership (#2515)

* fix(compiler): preserve writable branch captures (#2511)

* fix(codemod): preserve native host ref state in Strong mode (#2517)

* fix(codemod): preserve native host ref state in Strong mode

* fix(codemod): verify the binding of native ref owners

* fix(codemod): preserve opaque array map dispatch (#2512)

* fix(codemod): preserve opaque array map dispatch

* fix(examples): make Hacker News list dispatch explicit

* test(codemod): verify Hacker News fresh lists in Strong mode

* fix(codemod): report opaque effect dependency getters (#2516)

* fix(codemod): report opaque effect dependency getters

* fix(codemod): check effect getters in JSX-free templates

* fix(codemod): preserve keyed JSX row evaluation order (#2518)

* fix(codemod): preserve keyed JSX row evaluation order

* fix(codemod): preserve keyed rows with multiline JSX children

* feat(testing): add installTestClock, one host seam for runtime time (#2519)

* feat(testing): add installTestClock, one host seam for runtime time

Route the runtime's timers, animation frames, host tasks and now() through
host-task.ts so one installed clock decides their order. octane/testing's
installTestClock() owns that clock: advance(ms), frame() and settle() move
it; act() runs work that is already due without moving time; uninstall()
hands held work back to the host. Converts the flaky ViewTransition
pre-render passive test from half-faked timers to the clock.

Phase 1 of #2508.

Co-Authored-By: Claude <[email protected]>

* fix(testing): keep host-task DOM-free and create the post-paint channel eagerly

host-task.ts is part of DOM-free programs (ink, opentui), so read
requestAnimationFrame and document through a typed globalThis instead of
naming DOM globals. Restore creating the post-paint MessageChannel when
passive work is scheduled, as lazy-client-initialization pins, rather
than inside the frame callback.

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(compiler): type generated child traversal on opaque DOM hosts (#2520)

* fix(codemod): retain async and generator map results (#2521)

* fix(codemod): keep retained maps renderable in directive arms (#2522)

* fix(codemod): report generated Intl formatter ownership (#2523)

* fix(octane): preserve type imports in the native TypeScript parser (#2525)

* feat(compiler): hint Strong reads of state after its own setter (#2526)

* feat(compiler): hint Strong reads of state after its own setter

* fix(compiler): scope read-after-set updates per switch case; list recipe in Strong skill

* feat(data): WebSocket and broker feed listeners, and feed cursors across restarts (#2524)

* feat(data): WebSocket and broker feed listeners, and feed cursors across restarts

webSocketListener streams feeds over a socket that handler.accept serves
with no time limit, refusing other origins. pubSubListener listens through a
broker the page already uses. A persistent store saves each feed's cursor
with its stale marks, so the next session replays what it missed, and an
event marks saved copies it could not reach in memory stale.

Co-Authored-By: Claude <[email protected]>

* fix(data): back off a WebSocket feed the server closes with an error

A browser calls any completed close handshake clean, so a refused (1008) or
failed (1011) socket reconnected at once. Only a normal close now ends a
connection without an error, and with Octane's protocol a socket counts as
live once accept has read its request.

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* chore(changeset): release installTestClock and data feed listeners as patches (#2527)

* chore(changeset): release installTestClock as a patch

* chore(changeset): release data feed listeners as a patch

* feat(testing): put data, hydration and signals timing on the test clock (#2529)

Phase 2 of #2508. Route octane/data freshness, retention, persistence
stamps and feed backoff, idle and streamed hydration timers, deferred
event fallbacks, signal action timeouts, resize-observer delivery and the
universal re-settle retry through host-task.ts. Add hostDateNow() and
TestClock.dateNow() so data freshness follows the clock, and let the
clock respect a hidden page. Convert transition-timeout and effect-timing
off Vitest fake timers, run the data freshness test on the clock, and add
an idle-hydration clock test.

Co-authored-by: Claude <[email protected]>

* feat(data): carry feed positions in a server render's seed (#2530)

* feat(data): carry feed positions in a server render's seed

A store with no listen asks each feed in its new feeds option for its
position before its first read, and its seed carries them, so the browser's
feed resumes from before the page's values loaded. The data handler answers
a position request with the first cursor the feed's handler yields when it
starts with none.

Co-Authored-By: Claude <[email protected]>

* fix(data): stop a server render's feed position request when its store retires

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(octane): suspend a list of suspending rows once, not once per row (#2528)

* fix(octane): suspend a list of suspending rows once, not once per row

Co-Authored-By: Claude <[email protected]>

* fix(octane): pace rejected row thenables and fold row deferral without suspension

Co-Authored-By: Claude <[email protected]>

* perf(octane): keep row suspension collection out of bundles that cannot suspend

Co-Authored-By: Claude <[email protected]>

* test(octane): pin row-ordered request starts for suspending keyed lists

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(compiler): suggest useInitialValue for nested readonly bindings (#2533)

* fix(codemod): preserve eager prop reads in state initializers (#2536)

* fix(codemod): move effect-only ref helpers into their effect (#2535)

* fix(codemod): guard escaped scoped-store handles (#2537)

* fix(codemod): respect nested React Intl export conditions (#2538)

* fix(codemod): resolve effect restart triggers by binding (#2539)

* fix(compiler): diagnose state updates through bound effect schedulers (#2544)

* fix(codemod): report React Intl scalar formatter ownership (#2543)

* feat(testing): put server and RPC deadlines on the test clock (#2531)

* feat(testing): put server and RPC deadlines on the test clock

Part 1 of phase 3 of #2508. Route the SSR suspense deadline, the stalled
reader backoff and its deadline, streamed-signal budgets, server-function
batch and stream timeouts, the server-function client deadline and timer,
octane/data's server long-poll lifetime and the React-hosted SSR timeout
through host-task.ts. SSR's macrotask yield stays on real time: it waits
for real I/O. Convert the prerender deadline, stalled-reader deadline and
RPC client deadline tests to the clock.

Co-Authored-By: Claude <[email protected]>

* fix(testing): keep TestClock.dateNow() in whole milliseconds

The clock's time starts at performance.now() and frame() snaps to 16 ms
boundaries, so dateNow() could be fractional. Date.now() never is, and
callers rely on that: the server-function client passed a fractional
leftover deadline to serverResultLimits, which requires an integer, and
threw a RangeError. Floor the clock's date, as Date.now() would be.

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(radix): ignore deferred outside presses on registered branches (#2534)

* test(tanstack-virtual): render the SSR hydration fixture in beforeAll (#2550)

* test(tanstack-virtual): render the SSR hydration fixture in beforeAll

The test body started a cold Vite SSR server and compiled the whole server
runtime before hydrating. That setup is ~0.5 s idle and 2.2-2.7 s on the
loaded React parity shard 2/4, with a tail past the 5 s test budget; the
hydration under test takes ~20 ms. Render the server twin in beforeAll, as
the input-otp and alien-signals hydration suites already do.

* test(tanstack-virtual): refresh the ssr-hydration parity evidence hash

* fix(data): preserve ambiguous writes and fence dispatch after retirement (#2540)

* fix(data): preserve ambiguous writes and fence dispatch after retirement

* test(data): narrow the uncertain write before settling it

* test(data): wait for dispatch before retiring the test store

* fix(data): keep newer reads when write replies arrive out of order (#2541)

* fix(data): keep newer reads when write replies arrive out of order

* fix(data): reuse a matching feed reply and reconcile a partial update

* test(data): cover deletions outside the current read and view

* fix(data): preserve confirmed SSR snapshots and lazy seed age (#2546)

* fix(data): preserve confirmed SSR snapshots and lazy seed age

* refactor(data): keep serialized seed entries uniform

* fix(codemod): migrate scoped-store uses in Effect Events (#2552)

* fix(codemod): migrate render latches initialized from boolean props (#2551)

* fix(data): preserve native form retry identity and retire held forms (#2547)

* fix(data): preserve native form retry identity and retire held forms

* fix(data): preserve native form retry identity and retire held forms

* fix(data): keep mounted form hooks idle after retirement

* test(data): cancel native submit on a retired mounted form

* fix(data): discard frames after a feed disconnects (#2545)

* fix(data): discard frames after a feed disconnects

* docs(data): explain retirement at the feed delivery boundary

* fix(codemod): protect React island source modules before writing (#2554)

* fix(codemod): protect React island source modules before writing

* fix(codemod): follow logical React island component values

* fix(data): preserve recovery state until cache updates are durable (#2542)

* fix(data): preserve recovery state until cache updates are durable

* fix(data): reconcile obsolete journal entries and retry a failed flush

* fix(data): retain prepared cache values across storage retries

* fix(data): preserve wire input identity and rejoin evicted reads (#2548)

* fix(data): preserve wire input identity and rejoin evicted reads

* fix(data): preserve wire input identity and rejoin evicted reads

* test(effect-atom): wait for scheduled task completion (#2553)

* test(effect-atom): wait for scheduled task completion

* test(effect-atom): refresh scheduled-task parity evidence

* fix(codemod): recover shorthand types for stable scalar props (#2555)

* fix(codemod): recover shorthand types for stable scalar props

* fix(codemod): defer shorthand recovery for unresolved value imports

* fix(codemod): check imported JSX before migrating scoped-store arguments (#2556)

* fix(codemod): check imported JSX before migrating scoped-store arguments

* fix(codemod): resolve the value of merged scoped-store exports

* fix(data): reconcile persisted and server-rendered feed cursors (#2549)

* fix(data): reconcile persisted and server-rendered feed cursors

* fix(data): reconcile persisted and server-rendered feed cursors

* fix(data): persist the reconciled cursor on idle streams

* feat(data): one owner for several replica stores over message ports (#2559)

* feat(data): one owner for several replica stores over message ports

Co-Authored-By: Claude <[email protected]>

* fix(data): reloads never join an older shared read; followed creates gate edits

A replica asking again for a read it already asked for is reloading, so the
owner starts a new request rather than answering it with one that may predate
the change, and only the newest read for a key shares its value. A replica
following another tab's create now holds that record's queue behind its
outcome, as the sending tab does.

Co-Authored-By: Claude <[email protected]>

* fix(data): a replica recognises a view's reload by its wire key

Co-Authored-By: Claude <[email protected]>

* fix(data): only reads count toward a replica's reload record

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* feat(mcp-server): agent driver that drives an Octane app on the test clock (#2558)

* feat(mcp-server): agent driver that drives an Octane app on the test clock

Adds the octane/agent entry, which installs the test clock ahead of the app's scripts, and nine octane_app_* MCP tools that drive one page of a Vite dev server in Chromium (#2508 phase 3).

* style(mcp-server): format agent driver files

* fix(mcp-server): serve the agent module under Vite's base

* fix(codemod): retain installed data descriptors in scoped-store effects (#2561)

* fix(codemod): trace scoped-store JSX through wildcard exports (#2562)

* fix(codemod): check React hook dependency getters (#2563)

* feat(data): share one owner between tabs through a SharedWorker (#2560)

* feat(data): share one owner between tabs through a SharedWorker

Co-Authored-By: Claude <[email protected]>

* fix(examples): declare the shared-owner journey in Shelf's example.json

Co-Authored-By: Claude <[email protected]>

* test(compiler): count emitFile chunk records as bundler records in the AST emit audit

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(codemod): keep deferred store field ownership diagnostics (#2566)

* fix(codemod): flag destructured bare SVG components (#2564)

* fix(codemod): flag destructured bare SVG components

* fix(codemod): check the final selected SVG record field

* fix(codemod): trace render-time scoped-store results (#2565)

* fix(codemod): report SSR hints called by inline state initializers (#2568)

* test(swr): isolate the pristine retry callback clock (#2570)

* feat(codemod): migrate static SVG circles and root data (#2571)

* fix(octane): dispatch custom JSX map before receiver checks (#2569)

* fix(codemod): check conditional hook dependency getters (#2573)

* fix(codemod): report generated Intl formatter ownership (#2574)

* fix(codemod): report generated Intl formatter ownership

* test(codemod): preserve Intl upgrade ownership findings

* feat(data): fence shared owners by the origin's signed-in account (#2572)

* feat(data): fence shared owners by the origin's signed-in account

Co-Authored-By: Claude <[email protected]>

* fix(data): bump the owner protocol for hello, and retry a failed account record

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* feat(codemod): preserve fresh inline imperative handles (#2576)

* fix(codemod): report unchanged React context hooks (#2577)

* fix(codemod): report ownership for all scalar Intl formatters (#2579)

* fix(vite-plugin): forward dataWorker to the compiler plugin (#2578)

* docs(data): document octane/data across the website, llms.txt, MCP and READMEs (#2575)

* docs(data): add the octane/data guide, reference, and llms/MCP coverage

Add a website Data guide (Octane and React examples, six diagrams), a
docs/data.md reference served by the MCP server, llms.txt coverage, and
links from the READMEs, sitemap, and Signals guide. A docs test compiles
every example and checks the reference tables against real exports.

* fix(data): typecheck persist.key under bun-types

bun-types declares CryptoKey so it survives a typeof function check. The
website program loads bun-types and now type-checks octane/data through
the new docs test, which failed on persist.ts.

* docs(data): document account fencing for shared owners (#2572)

* docs(data): give each sequence diagram step its own grid row

Auto-placement could put a later step beside an earlier one; an explicit
row keeps the numbered messages reading top to bottom.

* fix(compiler): allow data maps with unreachable JSX (#2581)

* fix(compiler): preserve JSX map addition order (#2582)

* fix(compiler): preserve JSX map conversion order (#2585)

* fix(website): preserve playground AST pins during startup (#2584)

* feat(data): shared tabs fall back to their own store, and survive other builds and crashes (#2583)

* feat(data): shared tabs fall back to their own store, and survive other builds and crashes

Co-Authored-By: Claude <[email protected]>

* fix(data): serve a tab again when it wakes after being dropped, and count unanswered pings

A silent tab is dropped from feeds but served again if it speaks under the same
generation. A tab detects a lost owner after three unanswered pings rather than
wall-clock silence, so throttled background timers never cause a reconnect, and
pauses its heartbeat while frozen. Format data.mdx.

Co-Authored-By: Claude <[email protected]>

* fix(data): restart the owner's sweep when a dropped tab is served again

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix: preserve shadowed createPortal calls (#2588)

* fix: preserve shadowed createPortal calls

* fix: keep shadowed portal-spelled callbacks callable

* fix: preserve shadowed template factory callbacks (#2591)

* fix(codemod): report nested React islands in hosted SSR (#2590)

* fix(codemod): report nested React islands in hosted SSR

* fix(codemod): check paired OctaneCompat tags

* fix(codemod): inspect default JSX exports in SSR hosts

* chore(changeset): release recent features as patches (#2601)

* fix(codemod): verify the final Strong repair (#2595)

* fix(codemod): diagnose SVG namespace default tags (#2598)

* feat(data): read one way, with useRead(store.read(...)) (#2600)

* feat(data): read one way: useRead(store.read(...)), with { suspend: false } for the snapshot

Co-Authored-By: Claude <[email protected]>

* test: read data through useRead(store.read(...)) in the plugin fixtures; patch changeset

Co-Authored-By: Claude <[email protected]>

* feat(data): drop useWrite; components write with useDataStore().write(...)

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(codemod): report unchanged React root components (#2604)

* feat(data): the shared owner is the only writer of an account's cache and journal (#2594)

* feat(data): the shared owner is the only writer of an account's cache and journal

Co-Authored-By: Claude <[email protected]>

* fix(data): a tab with no owner uses its own cache; protocol 4; sign-out answers recover with no entries

Co-Authored-By: Claude <[email protected]>

* chore: release the shared cache as a patch

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(codemod): report retained React callback hooks (#2607)

* test(octane): wait for persistence marks retry

* fix(compiler): evaluate parent props before a render retry (#2603)

* fix(compiler): evaluate parent props before a render retry

* fix(compiler): recognize type-only wrappers on retry operands

---------

Co-authored-by: Dominic Gannaway <[email protected]>
Co-authored-by: Claude <[email protected]>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
domgan-oai added a commit that referenced this pull request Nov 13, 2026
)

* feat: let packages declare Strong mode and applications require it (#2400)

* feat: let packages declare Strong mode and applications require it

Packages declare Strong in package.json with "octane": { "strong": true }
or a list of paths. compiler.strongDependencies: { require, allow } fails the
build with OCTANE_STRONG_DEPENDENCY when an application module reaches a
non-Strong module in another Octane package or an octane/react boundary. The
walk moves from the CLI into the compiler, so octane analyze previews exactly
what the build rejects.

The six packages the website renders declare their Strong modules, and the
website turns require on with an empty allow list. Its playground version
picker replaces @octanejs/base-ui's Combobox with a local listbox.

Refs #2059

Co-Authored-By: Claude <[email protected]>

* fix: address review on Strong dependency requirement

- Vite plugin: always read octane.config.ts, so strongDependencies is not
  dropped when strong and renderers are both passed inline.
- octane analyze: keep going under require when there are no views, so plain
  application modules are still checked.
- Playground version picker: keep focus in the input on any press inside the
  list, not only on option rows.

Co-Authored-By: Claude <[email protected]>

* fix(website): let the version list's scrollbar scroll

A mousedown preventDefault on the scrolling list also blocked its scrollbar.
The list now takes focus itself (tabIndex -1), and the field closes the popup
only when focus leaves it. Choosing an option returns focus to the input.

Co-Authored-By: Claude <[email protected]>

* fix(website): close the version list through the bubbling onBlur

Octane's onBlur is delegated as focusout, as React's is, and it is the
typed name; onFocusOut is not.

Co-Authored-By: Claude <[email protected]>

* fix(website): return focus to the version input on Escape

The list can hold focus, so hiding it on Escape dropped focus to the page.

Co-Authored-By: Claude <[email protected]>

* fix(compiler): name the Strong dependency code in its message

The printed-code audit rejects interpolating a non-diagnostic `.code`.

Co-Authored-By: Claude <[email protected]>

* test(website): expect the package reason in Strong module status

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* feat(codemod): migrate verified path-only SVG components (#2398)

* fix(codemod): trace SVGs through native renderable props (#2402)

* feat(codemod): migrate verified path-only SVG components

* fix(codemod): trace SVGs through native renderable props

* fix(codemod): follow proven renderable TypeScript wrappers

* fix(signals): replay optimistic$ updaters over newer source values (#2401)

* fix(signals): replay optimistic$ updaters over newer source values

An overlay kept the value its updater produced at write time, so a refetch,
stream value or direct write stayed hidden behind a pending edit, and a
rejected operation's edit survived inside a later operation's value. Keep
each operation's writes and replay them in order over the current source,
as useOptimistic rebases its updates.

* fix(signals): show an optimistic$ overlay that produces undefined

* fix(data): server-assigned IDs for creates, and one commit per server transaction (#2404)

* fix(data): server-assigned IDs for creates, and one commit per server transaction

A create can name where the server's ID is in its reply. Writes to the new
record wait for the create, are sent with the server's ID, and are refused
unsent if the create is refused. Every view a reply or an optimistic edit
changes is recomputed before any reader is notified.

* fix(data): keep a created record's writes in order across its new ID, and end them on retire

* fix(codemod): ignore erased references in SVG ownership checks (#2406)

* fix: remove the website's remaining client descriptors (#2405)

* feat(strong): reject markup outside template output

Strong mode now reports OCTANE_STRONG_VALUE_JSX for JSX returned from a
function, assigned, passed as a prop or argument, or chosen by an
expression, and for @{} blocks stored in objects or chosen by an
expression: each builds an element descriptor. The website, devtools tabs,
and compiled Router document no longer build descriptors on the client.

ErrorBoundary renders a fallback={@{ ... }} body instead of calling it as a
render prop, and the codemod lowers plain-reference && guards in Strong
output to @if/@else.

Refs #2059

* revert(strong): allow value JSX again; keep the ErrorBoundary and document fixes

Value JSX already compiles to a template behind an 'r:' record, so Strong
keeps accepting it. This drops OCTANE_STRONG_VALUE_JSX, the codemod guard
lowering, and the test conversions it required.

Kept: ErrorBoundary renders a fallback={@{ ... }} body instead of calling it,
the compiled Router document leaves server-only html/head/body out of client
builds, DevtoolsDemo's Suspense fallbacks are render bodies, and an MDX page
no longer nests a <p> inside a <p>.

* test(data): compare cached responses with a normalized worker store (#2408)

* test(data): compare cached responses with a normalized worker store on library journeys

Runs four library journeys and a cold start from storage against octane/data
as merged and a prototype normalized store that evaluates declared views in
a worker. Measures views shown, bytes fetched and persisted, worker traffic,
impossible states and feature code, as promised on #2362.

* test(data): add a normalized design that loads view windows instead of every book

* test(data): refuse journey 3's star by book ID, so the rename cannot let it through

* fix(codemod): report bare SVG issuer changes in ordinary components (#2407)

* fix(codemod): report bare SVG issuer changes in ordinary components

* fix(codemod): trace bare SVGs selected by component fallbacks

* fix(codemod): check SVG defaults on local destructuring

* fix(codemod): exclude SVG defaults overridden by an inline object

* fix(tanstack-router): keep the server document out of browser builds (#2409)

* fix(tanstack-router): keep the server document out of browser builds

The compiled Html, Head, and Body read their server-only document
components through #server-document, which resolves to a null stub under
the browser condition. Folding isServer already removed those components
from client chunks, but Rolldown had linked their createScopedElement
import first and kept it exported from the runtime chunk.

Refs #2059

* test(tanstack-router): classify the server document resolution test

* feat(codemod): migrate path SVGs with conditional clsx tokens (#2411)

* feat(data): read the store as native Octane signal reads (#2410)

* feat(data): read the store as native Octane signal reads

The Octane binding reports each store read to the renderer as a native read
source, so components subscribe as they do to signal$ and query$ and need no
hook slot. The store calls its transport after the synchronous work that
started a load, so a read during render never runs it inside the render.

* fix(data): deliver store changes to Octane readers outside the transition

Native-read notifications honored the ambient transition, so a write inside
startTransition queued its optimistic edit behind the transition. runUrgent
clears the transition context around the notification, as
useSyncExternalStore's scheduleUrgentRender does.

* feat(codemod): migrate static SVG groups and rectangles (#2412)

* feat(data): declared lists with view() (#2413)

* feat(data): declared lists with view()

A view defines a list by a rule over an entity. It loads its window plus a
margin, shares records with every other view of the entity, and evaluates its
rule locally, so an edit moves a record into, out of or across every view in
the task that made it. A write can name its saved record with `record`, which
views take in place of reloading. The Shelf example moves onto views.

* fix(data): keep paged views within max and wait for edits before reloading short windows

A later page took a left margin on top of a full window, so a page at the
view's max was refused; the margins now give way to the cap. A window that
unconfirmed edits left short reloaded on every new span until they settled;
it now reloads once the server has those edits.

* feat(codemod): prove ownership of presence-tested SVG props (#2415)

* feat(data): native forms for writes (#2414)

* feat(data): native forms for writes

A write that declares `form` fields can be submitted by a plain HTML form,
which works before hydration and with JavaScript off. `useForm(write, key?)`
gives the form its attributes, hidden fields, pending state, submitted values
and field issues; once hydrated it submits through the store with the write's
optimistic edit. On the server, `forms(request)` runs a native submission and
answers 303, or returns the refusal for the page to render again, and signs
each page's forms for its account. The Shelf example's add and remove move
onto forms, with JavaScript-off and hydration journeys.

* chore(data): format forms files and refresh the example catalog

The new forms module and its tests were untracked when formatted, and the
Shelf journey added to example.json changes the generated catalog and its
e2e shard weights.

* fix(data): let go of a form that unmounted while its submission was in flight

A form handle was released only on unsubscribe while idle, so one that
unmounted mid-submission, as every removed row does, stayed in the store for
the rest of the session. It now also lets go when its submission settles with
no subscribers.

* feat(data): encrypted persistent cache with a size budget (#2416)

* feat(data): encrypted persistent cache with a size budget

A store given `persist: { storage, partition, key, budget }` saves each
read's confirmed value, and each view's confirmed rows, and starts from them
after a restart with their age kept. Values are encrypted with AES-GCM under a
key from the session, and every name the storage sees is a keyed hash, so
people sharing a browser can neither read nor list each other's values. A
value saved under another shape of its read's output schema, where the
validator describes one, or another `version`, is discarded; one that fails
validation on restore is too. Saves are coalesced per host task and the
partition is purged to its budget, expired values first and then the least
recently used, never one a mounted component shows. The budget defaults to a
size chosen by device memory, data saving and quota. `indexedDBStorage()` and
`memoryStorage()` are included. The Shelf example persists its store.

* fix(data): save reads a write carries back, and count restores as recent use

A write reply's refreshed reads were adopted but never saved, so a reload
within their freshness showed the value from before the write. A restored
value's last use reached only the next storage write, not the order purging
reads, so it could be purged before older unused values.

* feat(codemod): follow SVGs through single-read render locals (#2417)

* feat(codemod): follow SVGs through single-read render locals

* fix(codemod): preserve evaluation and early-return boundaries

* fix(data): restore values a write marked stale as stale, and never purge in-use values at startup (#2419)

* fix(data): restore values a write marked stale as stale, and never purge in-use values at startup

A write or `invalidate()` marked only the entries in memory, so a value saved
earlier and restored within its freshness showed data from before the write.
Each tag and entity name now keeps the time it was last marked, in its own
encrypted record, and each saved value the time it was saved and the names it
holds; a value marked after it was saved is restored stale.

The startup purge ran before any component had asked for a value, so it could
delete values mounted components were about to restore. It now removes only
expired values; the budget applies from the first save.

* fix(data): save invalidation marks again after a failed save

The marks were flagged saved before the write finished and a failed write was
ignored, so its invalidations were lost and a later restart could show a value
from before the write as fresh. A failed save now leaves them flagged, and the
next save writes them.

* feat(codemod): migrate SVG classes from CSS Modules (#2420)

* feat(data): durable writes that survive a restart (#2422)

* feat(data): durable writes that survive a restart

Writes listed in `persist.journal` are saved to an encrypted journal, in the
cache's storage, before they are sent, and leave it once their outcome is
known. After a restart the store shows each journaled write's edit again and
reads the journal's `receipt` with its operation ID: an applied receipt keeps
the edit, any other rolls it back, and the write is never sent twice. A write
whose receipt cannot be read stays for the next start; one this build no
longer declares, or whose input it no longer accepts, is dropped. `retire()`
clears the journal. The Shelf example's writes are durable.

* fix(data): recover journaled writes in submission order, and retry failed removals

Storage lists the journal by hashed name, so recovered writes came back in an
arbitrary order and a later edit could lose to an earlier one. Each entry now
carries its submission order and recovery sorts by it. A failed removal from
the journal was dropped, so a settled write could come back after the next
start; it is now tried again at the next save.

* fix(codemod): defer mutable SVG clsx guards (#2423)

* fix(codemod): defer mutable SVG clsx guards

* perf(codemod): reuse fixed SVG parameter proofs

* feat(data): server-ordered reads share records with views (#2424)

* feat(data): server-ordered reads share records with views

A read that selects entities but only the server can order, such as search
results, keeps the order and membership it was sent but now shares records
with the views. Its load gives views any newer copy of a record they hold,
and it shows any copy newer than its own load, from a view, another read or a
write's `record`. A load notifies every read sharing its entities. Copies are
compared by field, and an unchanged projection keeps its identity, so a read
whose shared records did not change keeps its snapshot, even with an edit
pending.

* fix(data): share only records views hold, and tell views and the cache when a read shares one

A server-ordered read inserted every record it carried into the shared table,
so a late one could put back a record a view had since dropped; it now only
updates records the table holds. Reads a write's reply carried back now
notify every read sharing their entities, as a load does. And a read that
gives views a newer copy marks those views for saving.

* feat(codemod): pass workspace stores to deferred local helpers (#2425)

* feat(codemod): pass workspace stores to deferred local helpers

* fix(codemod): prove the native click output owner

* perf(data): read the store through useSyncExternalStore on the client again (#2429)

The client binding reported each store read to the renderer as a native signal
read. Measured against useSyncExternalStore on the same production app, with
identical renders and DOM, the native path was slower in every step large
enough to measure, and importing it turned on read collection around every
component's render, including ones that read no data. Both bindings now read
snapshots through useSyncExternalStore, as React does; the client entry is
about 3 KB gzipped smaller.

* feat(codemod): migrate native submit event annotations (#2426)

* feat(codemod): migrate native submit event annotations

* fix(codemod): verify forwarded submit event callbacks

* fix(codemod): isolate submit exports and callback slots

* fix(codemod): resolve contextual submit event types

* fix(codemod): keep deferred React submit import types

* fix(codemod): verify workspace store helper dependencies (#2430)

* fix(codemod): verify workspace store helper dependencies

* fix(codemod): trace runtime class bases in store helpers

* test(data): stabilize persistence cache assertions (#2431)

* feat(codemod): preserve explicit effect restart triggers (#2427)

* fix(codemod): trace Intl props through native forwarding wrappers (#2433)

* fix(codemod): preserve inline React Intl substitutions (#2432)

* feat(data): serve a store through a module server function (#2434)

* feat(react): support inline ReactCompat hosts (#2436)

* feat(codemod): lower JSX lists over dense array literals (#2435)

* feat(codemod): lower JSX lists over dense array literals

* fix(codemod): recognize type-wrapped dense iterables

* feat(app-core): serve module server functions from a custom server; Shelf over RPC with Vite and Rspack (#2440)

* feat(app-core): serve module server functions from a custom server; Shelf over RPC with Vite and Rspack

* fix(shelf): keep each Rspack compiler's output apart; pass Vite's own requests through untouched

* feat(data): publish, forget, awaitable retire and opaque cache keys (#2443)

* feat(data): publish, forget, awaitable retire and opaque cache keys (#2439)

* fix(data): let reads join a publish, and keep the saved copy when one is refused

* fix(codemod): defer opaque scoped store inputs (#2428)

* feat(codemod): trace scoped store factory wrappers

* fix(codemod): defer opaque scoped store inputs

* fix(codemod): keep opaque origins through imports and type wrappers

---------

Co-authored-by: Dominic Gannaway <[email protected]>

* feat(floating-ui): add standalone positioning entry (#2438)

* feat(floating-ui): add standalone positioning entry

* fix(floating-ui): classify positioning-only parity tests

* feat(codemod): migrate provider-owned React Intl locales (#2442)

* feat(codemod): migrate destructured React Intl locales

* fix(codemod): prove ownership of destructured Intl locales

* perf(data): evaluate each view from an index of the records its window holds (#2446)

* fix(codemod): migrate expression-bodied effects with explicit dependencies (#2445)

* test(codemod): retain diagnostics for opaque React Intl service calls (#2437)

* feat(codemod): preserve deferred React Intl service values

* fix(codemod): accept discarded deferred Intl service calls

---------

Co-authored-by: Dominic Gannaway <[email protected]>

* fix(codemod): preserve key evaluation in guarded list rows (#2447)

* feat(data): page views with more, pages() and usePages() (#2449)

* feat(data): page views with more, pages() and usePages()

* fix(data): keep later pages shown while an expired earlier page reloads

* fix(data): retry a failed earlier page from loadMore, and stop reporting it as refreshing

* fix(codemod): preserve property triggers in explicit effect dependencies (#2450)

* fix(codemod): preserve setup before keyed map rows (#2453)

* fix(codemod): preserve setup before keyed map rows

* fix(codemod): recognize inert primitive row keys

* fix(compiler): share keyed row destructuring with the row body (#2455)

* fix(compiler): share keyed row destructuring with the row body

* fix(compiler): preserve const row bindings in SSR keys

* test(compiler): expect one SSR row default evaluation

* fix(compiler): retain keyed text rows across equivalent bindings

* fix(codemod): enable React adapters on Octane 0.17 (#2468)

* fix(radix): project Slottable children without duplicating the host (#2473)

* fix(octane): preserve resource hints in React-hosted renders (#2490)

* fix(codemod): migrate React DOM root types (#2483)

* fix(codemod): migrate generic React event handlers (#2487)

* fix(codemod): preserve literal SVG data attributes (#2461)

* feat(octane): support a document body portal target (#2467)

* fix(octane): preserve universal imperative handle refs (#2471)

* fix(octane): preserve universal imperative handle refs

* test(drei): keep the PivotControls observer ref stable

* test(drei): refresh PivotControls parity evidence

* fix(compiler): preserve mapped JSX row keys (#2459)

* fix(compiler): preserve mapped JSX row keys

* fix(compiler): keep proven mapped tags on the native path

* fix(compiler): evaluate keys in empty mapped SSR rows (#2460)

* fix(codemod): migrate effect-only lazy mount records (#2463)

* feat(app-core): route seeds and a config data module for Vite and Rsbuild (#2492)

* feat(app-core): route seeds and a config data module for Vite and Rsbuild

* fix(app-core): cancel a live route stream on request error, and never hydrate a data root as void

* fix(codemod): preserve conditional input identity (#2503)

* fix(codemod): preserve literal SVG root overrides (#2501)

* fix(codemod): allow type queries on store consumers (#2495)

* fix(codemod): preserve the React ref allocator (#2488)

* fix(codemod): migrate standalone Floating UI positioning (#2475)

* fix(codemod): detect escaped eval in scoped store consumers (#2478)

* fix(compiler): preserve effectful JSX map callback order (#2474)

* fix(codemod): preserve authored inline React boundaries (#2479)

* feat(octane): capture initial render values in Strong mode (#2482)

* feat(octane): capture initial render values in Strong mode

* fix(compiler): preserve existing layout snapshot edits

* fix(release): separate Octane and Lynx snapshot changesets

* fix(compiler): preserve eager inputs to initial render snapshots

* test(codemod): assert eager snapshot repair during fallback

* test(cli): verify eager snapshot suggestions

* fix(codemod): prove React Intl locale ownership (#2477)

* fix(codemod): trace immutable store handle aliases (#2485)

* fix(codemod): preserve fresh imperative handles (#2499)

* fix(codemod): preserve fresh imperative handles

* fix(codemod): defer redeclared handle methods

* fix(codemod): preserve imperative handle receiver dependencies (#2470)

* fix(codemod): keep automatic React islands inside paragraphs (#2480)

* fix(codemod): preserve authored inline React boundaries

* fix(codemod): keep automatic React islands inside paragraphs

* fix(codemod): recognize published inline React host exports

* fix(codemod): keep conditional React islands inside paragraphs

* fix(codemod): follow imported fragments to paragraph hosts

* fix(codemod): adapt consolidated Radix Slot exports (#2472)

* fix(codemod): adapt consolidated Radix Slot exports

* fix(codemod): preserve local aliases that shadow Radix

* fix(codemod): preserve local Radix Slot import names

* fix(codemod): preserve SVG opacity and conditional classes (#2500)

* fix(octane): separate rewritten initial-value binding (#2505)

* fix(codemod): preserve SVG inline transforms (#2504)

* fix(codemod): preserve SVG inline transforms

* fix(codemod): recognize prior generated SVG helper

* feat(data): realtime feeds that keep loaded reads current (#2506)

* feat(data): realtime feeds that keep loaded reads current

Add feed() contracts, listen()/useFeed with one shared connection per feed
and parameters, and receive(store, changes). Events put or remove records,
replace a read's value, or invalidate tags. The store drops duplicate event
IDs, resumes from its cursor, and reloads what a feed covers after a gap.
createDataHandler serves feeds through handler.listen over a module server
function, read in the browser with serverListener. Shelf streams its changes
under Vite and Rspack.

Co-Authored-By: Claude <[email protected]>

* fix(data): reload a lower view window when a feed puts a record above it

Also have the Shelf feed check its history before waiting, so a write made
while a frame was being read is sent.

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(codemod): preserve fixed SVG colors (#2494)

* fix(codemod): preserve fixed SVG colors

* fix(codemod): recognize prior generated SVG helper

* fix(codemod): defer locally mutated store handles (#2493)

* fix(codemod): preserve custom and sparse JSX map dispatch (#2484)

* fix(codemod): migrate proven render-phase boolean state (#2465)

* fix(motion): support server rendering and hydration for motion hosts (#2491)

* fix(motion): support server rendering and hydration for motion hosts

* test(motion): classify the server host conformance tests

* fix(motion): preserve the initial frame during lazy feature loading

* fix(motion): release SVG frame for authored static values

* fix(codemod): preserve layout effect property dependencies (#2498)

* fix(codemod): migrate local rectangular SVG clipping (#2466)

* fix(codemod): migrate ref-only effect helpers (#2476)

* feat(codemod): migrate single-path SVG patterns (#2469)

* feat(codemod): migrate single-path SVG patterns

* fix(codemod): migrate static SVG path transforms

* fix(codemod): preserve SVG matrix transforms

* fix(codemod): report React hooks left in local helpers (#2464)

* fix(codemod): report React hooks left in local helpers

* fix(codemod): report React hooks after literal setup

* fix(codemod): defer React DOM-linked store inputs (#2486)

* fix(codemod): defer React DOM-linked store inputs

* fix(codemod): follow executable store dependencies

* fix(codemod): narrow resource hints to executable imports

* fix(codemod): preserve shared external-store hooks in native setup (#2481)

* fix(codemod): report React hooks left in local helpers

* fix(codemod): preserve shared external-store hooks in native setup

* fix(codemod): ignore type-only external-store hook references

* fix(codemod): preserve external-store hooks after null refs

* fix(codemod): report unsupported native hooks after null refs

* Version Packages (#2343)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

* fix(codemod): report lost SSR hints in imported state initializers (#2510)

* fix(codemod): report render-time scoped store member reads (#2513)

* fix(codemod): report unproven React Intl formatter ownership (#2515)

* fix(compiler): preserve writable branch captures (#2511)

* fix(codemod): preserve native host ref state in Strong mode (#2517)

* fix(codemod): preserve native host ref state in Strong mode

* fix(codemod): verify the binding of native ref owners

* fix(codemod): preserve opaque array map dispatch (#2512)

* fix(codemod): preserve opaque array map dispatch

* fix(examples): make Hacker News list dispatch explicit

* test(codemod): verify Hacker News fresh lists in Strong mode

* fix(codemod): report opaque effect dependency getters (#2516)

* fix(codemod): report opaque effect dependency getters

* fix(codemod): check effect getters in JSX-free templates

* fix(codemod): preserve keyed JSX row evaluation order (#2518)

* fix(codemod): preserve keyed JSX row evaluation order

* fix(codemod): preserve keyed rows with multiline JSX children

* feat(testing): add installTestClock, one host seam for runtime time (#2519)

* feat(testing): add installTestClock, one host seam for runtime time

Route the runtime's timers, animation frames, host tasks and now() through
host-task.ts so one installed clock decides their order. octane/testing's
installTestClock() owns that clock: advance(ms), frame() and settle() move
it; act() runs work that is already due without moving time; uninstall()
hands held work back to the host. Converts the flaky ViewTransition
pre-render passive test from half-faked timers to the clock.

Phase 1 of #2508.

Co-Authored-By: Claude <[email protected]>

* fix(testing): keep host-task DOM-free and create the post-paint channel eagerly

host-task.ts is part of DOM-free programs (ink, opentui), so read
requestAnimationFrame and document through a typed globalThis instead of
naming DOM globals. Restore creating the post-paint MessageChannel when
passive work is scheduled, as lazy-client-initialization pins, rather
than inside the frame callback.

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(compiler): type generated child traversal on opaque DOM hosts (#2520)

* fix(codemod): retain async and generator map results (#2521)

* fix(codemod): keep retained maps renderable in directive arms (#2522)

* fix(codemod): report generated Intl formatter ownership (#2523)

* fix(octane): preserve type imports in the native TypeScript parser (#2525)

* feat(compiler): hint Strong reads of state after its own setter (#2526)

* feat(compiler): hint Strong reads of state after its own setter

* fix(compiler): scope read-after-set updates per switch case; list recipe in Strong skill

* feat(data): WebSocket and broker feed listeners, and feed cursors across restarts (#2524)

* feat(data): WebSocket and broker feed listeners, and feed cursors across restarts

webSocketListener streams feeds over a socket that handler.accept serves
with no time limit, refusing other origins. pubSubListener listens through a
broker the page already uses. A persistent store saves each feed's cursor
with its stale marks, so the next session replays what it missed, and an
event marks saved copies it could not reach in memory stale.

Co-Authored-By: Claude <[email protected]>

* fix(data): back off a WebSocket feed the server closes with an error

A browser calls any completed close handshake clean, so a refused (1008) or
failed (1011) socket reconnected at once. Only a normal close now ends a
connection without an error, and with Octane's protocol a socket counts as
live once accept has read its request.

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* chore(changeset): release installTestClock and data feed listeners as patches (#2527)

* chore(changeset): release installTestClock as a patch

* chore(changeset): release data feed listeners as a patch

* feat(testing): put data, hydration and signals timing on the test clock (#2529)

Phase 2 of #2508. Route octane/data freshness, retention, persistence
stamps and feed backoff, idle and streamed hydration timers, deferred
event fallbacks, signal action timeouts, resize-observer delivery and the
universal re-settle retry through host-task.ts. Add hostDateNow() and
TestClock.dateNow() so data freshness follows the clock, and let the
clock respect a hidden page. Convert transition-timeout and effect-timing
off Vitest fake timers, run the data freshness test on the clock, and add
an idle-hydration clock test.

Co-authored-by: Claude <[email protected]>

* feat(data): carry feed positions in a server render's seed (#2530)

* feat(data): carry feed positions in a server render's seed

A store with no listen asks each feed in its new feeds option for its
position before its first read, and its seed carries them, so the browser's
feed resumes from before the page's values loaded. The data handler answers
a position request with the first cursor the feed's handler yields when it
starts with none.

Co-Authored-By: Claude <[email protected]>

* fix(data): stop a server render's feed position request when its store retires

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(octane): suspend a list of suspending rows once, not once per row (#2528)

* fix(octane): suspend a list of suspending rows once, not once per row

Co-Authored-By: Claude <[email protected]>

* fix(octane): pace rejected row thenables and fold row deferral without suspension

Co-Authored-By: Claude <[email protected]>

* perf(octane): keep row suspension collection out of bundles that cannot suspend

Co-Authored-By: Claude <[email protected]>

* test(octane): pin row-ordered request starts for suspending keyed lists

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(compiler): suggest useInitialValue for nested readonly bindings (#2533)

* fix(codemod): preserve eager prop reads in state initializers (#2536)

* fix(codemod): move effect-only ref helpers into their effect (#2535)

* fix(codemod): guard escaped scoped-store handles (#2537)

* fix(codemod): respect nested React Intl export conditions (#2538)

* fix(codemod): resolve effect restart triggers by binding (#2539)

* fix(compiler): diagnose state updates through bound effect schedulers (#2544)

* fix(codemod): report React Intl scalar formatter ownership (#2543)

* feat(testing): put server and RPC deadlines on the test clock (#2531)

* feat(testing): put server and RPC deadlines on the test clock

Part 1 of phase 3 of #2508. Route the SSR suspense deadline, the stalled
reader backoff and its deadline, streamed-signal budgets, server-function
batch and stream timeouts, the server-function client deadline and timer,
octane/data's server long-poll lifetime and the React-hosted SSR timeout
through host-task.ts. SSR's macrotask yield stays on real time: it waits
for real I/O. Convert the prerender deadline, stalled-reader deadline and
RPC client deadline tests to the clock.

Co-Authored-By: Claude <[email protected]>

* fix(testing): keep TestClock.dateNow() in whole milliseconds

The clock's time starts at performance.now() and frame() snaps to 16 ms
boundaries, so dateNow() could be fractional. Date.now() never is, and
callers rely on that: the server-function client passed a fractional
leftover deadline to serverResultLimits, which requires an integer, and
threw a RangeError. Floor the clock's date, as Date.now() would be.

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(radix): ignore deferred outside presses on registered branches (#2534)

* test(tanstack-virtual): render the SSR hydration fixture in beforeAll (#2550)

* test(tanstack-virtual): render the SSR hydration fixture in beforeAll

The test body started a cold Vite SSR server and compiled the whole server
runtime before hydrating. That setup is ~0.5 s idle and 2.2-2.7 s on the
loaded React parity shard 2/4, with a tail past the 5 s test budget; the
hydration under test takes ~20 ms. Render the server twin in beforeAll, as
the input-otp and alien-signals hydration suites already do.

* test(tanstack-virtual): refresh the ssr-hydration parity evidence hash

* fix(data): preserve ambiguous writes and fence dispatch after retirement (#2540)

* fix(data): preserve ambiguous writes and fence dispatch after retirement

* test(data): narrow the uncertain write before settling it

* test(data): wait for dispatch before retiring the test store

* fix(data): keep newer reads when write replies arrive out of order (#2541)

* fix(data): keep newer reads when write replies arrive out of order

* fix(data): reuse a matching feed reply and reconcile a partial update

* test(data): cover deletions outside the current read and view

* fix(data): preserve confirmed SSR snapshots and lazy seed age (#2546)

* fix(data): preserve confirmed SSR snapshots and lazy seed age

* refactor(data): keep serialized seed entries uniform

* fix(codemod): migrate scoped-store uses in Effect Events (#2552)

* fix(codemod): migrate render latches initialized from boolean props (#2551)

* fix(data): preserve native form retry identity and retire held forms (#2547)

* fix(data): preserve native form retry identity and retire held forms

* fix(data): preserve native form retry identity and retire held forms

* fix(data): keep mounted form hooks idle after retirement

* test(data): cancel native submit on a retired mounted form

* fix(data): discard frames after a feed disconnects (#2545)

* fix(data): discard frames after a feed disconnects

* docs(data): explain retirement at the feed delivery boundary

* fix(codemod): protect React island source modules before writing (#2554)

* fix(codemod): protect React island source modules before writing

* fix(codemod): follow logical React island component values

* fix(data): preserve recovery state until cache updates are durable (#2542)

* fix(data): preserve recovery state until cache updates are durable

* fix(data): reconcile obsolete journal entries and retry a failed flush

* fix(data): retain prepared cache values across storage retries

* fix(data): preserve wire input identity and rejoin evicted reads (#2548)

* fix(data): preserve wire input identity and rejoin evicted reads

* fix(data): preserve wire input identity and rejoin evicted reads

* test(effect-atom): wait for scheduled task completion (#2553)

* test(effect-atom): wait for scheduled task completion

* test(effect-atom): refresh scheduled-task parity evidence

* fix(codemod): recover shorthand types for stable scalar props (#2555)

* fix(codemod): recover shorthand types for stable scalar props

* fix(codemod): defer shorthand recovery for unresolved value imports

* fix(codemod): check imported JSX before migrating scoped-store arguments (#2556)

* fix(codemod): check imported JSX before migrating scoped-store arguments

* fix(codemod): resolve the value of merged scoped-store exports

* fix(data): reconcile persisted and server-rendered feed cursors (#2549)

* fix(data): reconcile persisted and server-rendered feed cursors

* fix(data): reconcile persisted and server-rendered feed cursors

* fix(data): persist the reconciled cursor on idle streams

* feat(data): one owner for several replica stores over message ports (#2559)

* feat(data): one owner for several replica stores over message ports

Co-Authored-By: Claude <[email protected]>

* fix(data): reloads never join an older shared read; followed creates gate edits

A replica asking again for a read it already asked for is reloading, so the
owner starts a new request rather than answering it with one that may predate
the change, and only the newest read for a key shares its value. A replica
following another tab's create now holds that record's queue behind its
outcome, as the sending tab does.

Co-Authored-By: Claude <[email protected]>

* fix(data): a replica recognises a view's reload by its wire key

Co-Authored-By: Claude <[email protected]>

* fix(data): only reads count toward a replica's reload record

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* feat(mcp-server): agent driver that drives an Octane app on the test clock (#2558)

* feat(mcp-server): agent driver that drives an Octane app on the test clock

Adds the octane/agent entry, which installs the test clock ahead of the app's scripts, and nine octane_app_* MCP tools that drive one page of a Vite dev server in Chromium (#2508 phase 3).

* style(mcp-server): format agent driver files

* fix(mcp-server): serve the agent module under Vite's base

* fix(codemod): retain installed data descriptors in scoped-store effects (#2561)

* fix(codemod): trace scoped-store JSX through wildcard exports (#2562)

* fix(codemod): check React hook dependency getters (#2563)

* feat(data): share one owner between tabs through a SharedWorker (#2560)

* feat(data): share one owner between tabs through a SharedWorker

Co-Authored-By: Claude <[email protected]>

* fix(examples): declare the shared-owner journey in Shelf's example.json

Co-Authored-By: Claude <[email protected]>

* test(compiler): count emitFile chunk records as bundler records in the AST emit audit

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(codemod): keep deferred store field ownership diagnostics (#2566)

* fix(codemod): flag destructured bare SVG components (#2564)

* fix(codemod): flag destructured bare SVG components

* fix(codemod): check the final selected SVG record field

* fix(codemod): trace render-time scoped-store results (#2565)

* fix(codemod): report SSR hints called by inline state initializers (#2568)

* test(swr): isolate the pristine retry callback clock (#2570)

* feat(codemod): migrate static SVG circles and root data (#2571)

* fix(octane): dispatch custom JSX map before receiver checks (#2569)

* fix(codemod): check conditional hook dependency getters (#2573)

* fix(codemod): report generated Intl formatter ownership (#2574)

* fix(codemod): report generated Intl formatter ownership

* test(codemod): preserve Intl upgrade ownership findings

* feat(data): fence shared owners by the origin's signed-in account (#2572)

* feat(data): fence shared owners by the origin's signed-in account

Co-Authored-By: Claude <[email protected]>

* fix(data): bump the owner protocol for hello, and retry a failed account record

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* feat(codemod): preserve fresh inline imperative handles (#2576)

* fix(codemod): report unchanged React context hooks (#2577)

* fix(codemod): report ownership for all scalar Intl formatters (#2579)

* fix(vite-plugin): forward dataWorker to the compiler plugin (#2578)

* docs(data): document octane/data across the website, llms.txt, MCP and READMEs (#2575)

* docs(data): add the octane/data guide, reference, and llms/MCP coverage

Add a website Data guide (Octane and React examples, six diagrams), a
docs/data.md reference served by the MCP server, llms.txt coverage, and
links from the READMEs, sitemap, and Signals guide. A docs test compiles
every example and checks the reference tables against real exports.

* fix(data): typecheck persist.key under bun-types

bun-types declares CryptoKey so it survives a typeof function check. The
website program loads bun-types and now type-checks octane/data through
the new docs test, which failed on persist.ts.

* docs(data): document account fencing for shared owners (#2572)

* docs(data): give each sequence diagram step its own grid row

Auto-placement could put a later step beside an earlier one; an explicit
row keeps the numbered messages reading top to bottom.

* fix(compiler): allow data maps with unreachable JSX (#2581)

* fix(compiler): preserve JSX map addition order (#2582)

* fix(compiler): preserve JSX map conversion order (#2585)

* fix(website): preserve playground AST pins during startup (#2584)

* feat(data): shared tabs fall back to their own store, and survive other builds and crashes (#2583)

* feat(data): shared tabs fall back to their own store, and survive other builds and crashes

Co-Authored-By: Claude <[email protected]>

* fix(data): serve a tab again when it wakes after being dropped, and count unanswered pings

A silent tab is dropped from feeds but served again if it speaks under the same
generation. A tab detects a lost owner after three unanswered pings rather than
wall-clock silence, so throttled background timers never cause a reconnect, and
pauses its heartbeat while frozen. Format data.mdx.

Co-Authored-By: Claude <[email protected]>

* fix(data): restart the owner's sweep when a dropped tab is served again

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix: preserve shadowed createPortal calls (#2588)

* fix: preserve shadowed createPortal calls

* fix: keep shadowed portal-spelled callbacks callable

* fix: preserve shadowed template factory callbacks (#2591)

* fix(codemod): report nested React islands in hosted SSR (#2590)

* fix(codemod): report nested React islands in hosted SSR

* fix(codemod): check paired OctaneCompat tags

* fix(codemod): inspect default JSX exports in SSR hosts

* chore(changeset): release recent features as patches (#2601)

* fix(codemod): verify the final Strong repair (#2595)

* fix(codemod): diagnose SVG namespace default tags (#2598)

* feat(data): read one way, with useRead(store.read(...)) (#2600)

* feat(data): read one way: useRead(store.read(...)), with { suspend: false } for the snapshot

Co-Authored-By: Claude <[email protected]>

* test: read data through useRead(store.read(...)) in the plugin fixtures; patch changeset

Co-Authored-By: Claude <[email protected]>

* feat(data): drop useWrite; components write with useDataStore().write(...)

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(codemod): report unchanged React root components (#2604)

* feat(data): the shared owner is the only writer of an account's cache and journal (#2594)

* feat(data): the shared owner is the only writer of an account's cache and journal

Co-Authored-By: Claude <[email protected]>

* fix(data): a tab with no owner uses its own cache; protocol 4; sign-out answers recover with no entries

Co-Authored-By: Claude <[email protected]>

* chore: release the shared cache as a patch

Co-Authored-By: Claude <[email protected]>

---------

Co-authored-by: Claude <[email protected]>

* fix(codemod): report retained React callback hooks (#2607)

* fix(codemod): preserve ordinary local provider members

* fix(compiler): evaluate parent props before a render retry (#2603)

* fix(compiler): evaluate parent props before a render retry

* fix(compiler): recognize type-only wrappers on retry operands

* fix(codemod): resolve local context aliases from their importing config

* fix(codemod): preserve context members on proven ordinary exports

* fix(codemod): recognize direct ordinary context-shaped objects

---------

Co-authored-by: Dominic Gannaway <[email protected]>
Co-authored-by: Claude <[email protected]>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agent-authored Diff or issue body substantially produced by an AI agent fix PR: bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Codemod misses React useCallback in unchanged local hooks

1 participant