vexSearchQuery
Implementation signature for the two vexSearchQuery overloads above — not
called directly with this shape. See the overloads for the public contract.
client
Any client exposing query(ref, args).
args
{ collection, searchIndexName, searchField, query, populate?, depth?, limit?, where?, drafts?, paginationOpts? }.
Call Signature
Section titled “Call Signature”vexSearchQuery<
TCollectionSlug,TPopulate,D>(client,args):Promise<DocReturnItem<TCollectionSlug,TPopulate,D>[]>
Defined in: packages/core/src/collections/api/networkQuery.ts:381
Searches documents in a collection by a search index via a direct network call.
Type Parameters
Section titled “Type Parameters”TCollectionSlug
Section titled “TCollectionSlug”TCollectionSlug extends string
TPopulate
Section titled “TPopulate”TPopulate extends ContainerPopulateShape<PopulateMapFor<TCollectionSlug>> = Record<string, never>
D extends number = 0
Parameters
Section titled “Parameters”client
Section titled “client”Any client exposing query(ref, args).
SearchClientArgs<TCollectionSlug, TPopulate, D> & object
{ collection, searchIndexName, searchField, query, populate?, depth?, limit?, where?, drafts?, paginationOpts? }.
Returns
Section titled “Returns”Promise<DocReturnItem<TCollectionSlug, TPopulate, D>[]>
The matching documents, or a PaginationResult when paginationOpts is given.
vexFindQuery for the client contract and why the funcRef cast is sound.
Call Signature
Section titled “Call Signature”vexSearchQuery<
TCollectionSlug,TPopulate,D>(client,args):Promise<SearchReturnPaginated<TCollectionSlug,TPopulate,D>>
Defined in: packages/core/src/collections/api/networkQuery.ts:389
Searches documents in a collection by a search index via a direct network call.
Type Parameters
Section titled “Type Parameters”TCollectionSlug
Section titled “TCollectionSlug”TCollectionSlug extends string
TPopulate
Section titled “TPopulate”TPopulate extends ContainerPopulateShape<PopulateMapFor<TCollectionSlug>> = Record<string, never>
D extends number = 0
Parameters
Section titled “Parameters”client
Section titled “client”Any client exposing query(ref, args).
SearchClientPaginatedArgs<TCollectionSlug, TPopulate, D>
{ collection, searchIndexName, searchField, query, populate?, depth?, limit?, where?, drafts?, paginationOpts? }.
Returns
Section titled “Returns”Promise<SearchReturnPaginated<TCollectionSlug, TPopulate, D>>
The matching documents, or a PaginationResult when paginationOpts is given.
vexFindQuery for the client contract and why the funcRef cast is sound.