useFind()
function useFind<T>(EntityType, options): RxDBResource<InstanceType<T>[]>;
Defined in: hooks.ts:203
Find multiple entities matching the criteria
Type Parameters
| Type Parameter |
|---|
T extends EntityType |
Parameters
| Parameter | Type | Description |
|---|---|---|
EntityType | T | The entity class |
options | UseOptions<EntityStaticType<T, "findOptions">> | Query options |
Returns
RxDBResource<InstanceType<T>[]>
A resource object containing an array of entities
Example
const { value: users } = useFind(User, { where: { age: { $gt: 18 } } });