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/electric-db-collection/type-aliases/AwaitTxIdFn.md
AwaitTxIdFn
ts
type AwaitTxIdFn = (txId, timeout?) => Promise<boolean>;Defined in: packages/electric-db-collection/src/electric.ts:873
Type for the awaitTxId utility function. It resolves when the txid appears in the Electric stream (the server's confirmation), before this tab's persistence accepts the transaction. If that commit later rejects, the source fails instead, and the Collection's health node records it (maintainer decision on PR #2265).
Parameters#
txId#
timeout?#
number
Returns#
Promise<boolean>