Skip to content

FindClientArgs

Defined in: packages/react/src/collections/api/find/client.ts:27

Client-side args for find. Extends GenericQueryClientParams to inherit ctx?: never, populate?: TPopulate, depth?: D, and skip?.

TCollectionSlug extends CollectionSlug = CollectionSlug

Collection slug.

TPopulate extends PopulateShape<TCollectionSlug> = PopulateShape<TCollectionSlug>

Populate object, narrowed against RelationshipKeysOf<TCollectionSlug>.

D extends number = number

Depth literal (0 = none). Inferred from depth.

optional auth?: undefined

Defined in: packages/core/src/collections/api/types.ts:88

Discriminator: client args MUST NOT supply auth.

GenericQueryClientParams.auth


collection: TCollectionSlug

Defined in: packages/react/src/collections/api/find/client.ts:32


optional ctx?: undefined

Defined in: packages/core/src/collections/api/types.ts:90

Discriminator: client args MUST NOT supply ctx.

GenericQueryClientParams.ctx


optional depth?: D

Defined in: packages/core/src/collections/api/types.ts:104

Auto-populate all relationship fields to this many levels.

Inferred as the literal D so a wrapper that threads D through to its return type narrows accordingly (depth: 2 → depth-populated doc). A non-literal number degrades to VexDocument via DepthPopulated’s guard. D defaults to number, so wrappers that do not thread it keep the plain passthrough they had before.

Use populate for documented consumer code; depth is internal.

GenericQueryClientParams.depth


optional drafts?: boolean

Defined in: packages/core/src/collections/api/types.ts:116

When true on a versioned collection, includes the document’s draft row alongside its published row — gated server-side on the readDrafts action (Step 13). Ignored for a non-versioned collection.

GenericQueryClientParams.drafts


optional limit?: number

Defined in: packages/react/src/collections/api/find/client.ts:33


optional paginationOpts?: PaginationOptions

Defined in: packages/react/src/collections/api/find/client.ts:44


optional populate?: TPopulate

Defined in: packages/core/src/collections/api/types.ts:92

Recursive populate object, type-narrowed against RelationshipKeysOf<TCollectionSlug>.

GenericQueryClientParams.populate


optional skip?: boolean

Defined in: packages/core/src/collections/api/types.ts:110

When true, the wrapper passes convexQuery’s "skip" sentinel instead of args, so the query is not issued. Use for conditional queries (e.g. an id that is not known yet) without violating the Rules of Hooks.

GenericQueryClientParams.skip


optional sort?: CollectionTableSort<string>

Defined in: packages/react/src/collections/api/find/client.ts:43

Portable sort — never an index name (Design Decision 5). Rejected server-side together with a search call (Design Decision 7).


optional where?: VexWhere<TCollectionSlug>

Defined in: packages/react/src/collections/api/find/client.ts:38

Predicate over the collection’s fields: a builder callback or a plain node. The callback is converted to a node before it is sent.