@octanejs/tanstack-db
v0.0.12
Published
TanStack DB bindings for Octane — reuses @tanstack/db's framework-agnostic core with Octane live-query hooks.
Readme
@octanejs/tanstack-db
Octane live-query hooks for TanStack DB.
Re-exports @tanstack/db unchanged and implements its
live-query binding surface on Octane hooks:
useLiveQueryuseLiveInfiniteQueryuseLiveSuspenseQueryuseLiveQueryEffectusePacedMutations
Install octane alongside this package and configure the Octane compiler in your
build tool (see octanejs.dev).
Compatibility
Ports the React live-query hooks of @tanstack/[email protected] onto Octane and
re-exports the framework-neutral @tanstack/[email protected] core unchanged.
useLiveQuery/useLiveSuspenseQuery run on db's shared createLiveQueryObserver
and useLiveInfiniteQuery on the coordinated createLiveQueryWindowController.
Intentional differences from React:
- Suspense integrates via Octane's
use(thenable)rather than throwing a raw promise (observable behavior — fallback then data — matches). useLiveInfiniteQueryrejects a pre-created collection that lacks anorderBysynchronously during render, so the error reaches the caller.- StrictMode double-invocation is not applicable (Octane has no development double-invoke).
See UPSTREAM.md for the pin and export crosswalk and status.json for the
tracked binding status.
