Skip to content
Source
Sign inSign up
TanStack/db
Open History to see the last commit

syncconfig.md

93 lines1.6 KB

Interface: SyncConfig<T, TKey>

Defined in: packages/db/src/types.ts:200

Type Parameters

• T extends object = Record<string, unknown>

• TKey extends string | number = string | number

Properties

getSyncMetadata()?

optional getSyncMetadata: () => Record<string, unknown>;

Defined in: packages/db/src/types.ts:216

Get the sync metadata for insert operations

Returns

Record<string, unknown>

Record containing relation information


rowUpdateMode?

optional rowUpdateMode: "partial" | "full";

Defined in: packages/db/src/types.ts:225

The row update mode used to sync to the collection.

Default

partial

Description

  • partial: Updates contain only the changes to the row.
  • full: Updates contain the entire row.

sync()

sync: (params) => void;

Defined in: packages/db/src/types.ts:204

Parameters

params
begin

() => void

collection

Collection<T, TKey, any, any, any>

commit

() => void

markReady

() => void

write

(message) => void

Returns

void