DB Docs
API Reference
- Core API Reference
- Collection
- createCollection
- liveQueryCollectionOptions
- createLiveQueryCollection
- createOptimisticAction
- createTransaction
- Electric DB Collection
- electricCollectionOptions
- Query DB Collection
- queryCollectionOptions
- RxDB DB Collection
- rxdbCollectionOptions
- PowerSync Collection
- powerSyncCollectionOptions
- createIndexedDB
- indexedDBCollectionOptions
- React Hooks
- useLiveQuery
AI/LLM: This documentation page is available in plain markdown format at/db/latest/docs/reference/functions/toBoundaryError.md
toBoundaryError
ts
function toBoundaryError(cause): Error;Defined in: packages/db/src/live-query-observer.ts:815
Internal
The Error an adapter sends to an error boundary for a failed first load or a crash: the cause itself when it is an Error, otherwise an Error with the problem's message (as in health.error.message) whose cause is the value the sync adapter reported.
Shared by TanStack DB's official framework adapters.
Parameters#
cause#
unknown
Returns#
Error