UNPKG

@tanstack/db

Version:

A reactive client store for building super fast apps on sync

11 lines (10 loc) 796 B
import { StandardSchemaV1 } from '@standard-schema/spec'; import { CollectionConfig, UtilsRecord } from './types.js'; export declare const collectionOptionsBrand: unique symbol; export declare const collectionOptionsFactory: unique symbol; export type CollectionOptionsIdentity<T extends object = Record<string, unknown>, TKey extends string | number = string | number, TSchema extends StandardSchemaV1 = never, TUtils extends UtilsRecord = UtilsRecord, TClient = unknown> = { readonly id: string; readonly [collectionOptionsBrand]: true; readonly [collectionOptionsFactory]: (client: TClient) => CollectionConfig<T, TKey, TSchema, TUtils>; }; export declare function hasCollectionOptionsBrand(value: unknown): value is CollectionOptionsIdentity<any, string | number, any, any, any>;