From f83353f6d37fadb4a0a2ad7a1bcc9edec76f3e0f Mon Sep 17 00:00:00 2001 From: Andrew Chou Date: Mon, 13 Jan 2025 16:38:53 -0500 Subject: [PATCH] fix: fix incorrect return type for useManyDocs() (#34) --- docs/API.md | 2 +- src/hooks/documents.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/API.md b/docs/API.md index b05e7ad..3914522 100644 --- a/docs/API.md +++ b/docs/API.md @@ -508,7 +508,7 @@ Retrieve all documents of a specific `docType`. | Function | Type | | ---------- | ---------- | -| `useManyDocs` | `({ projectId, docType, includeDeleted, lang, }: { projectId: string; docType: D; includeDeleted?: boolean or undefined; lang?: string or undefined; }) => ReadHookResult({ projectId, docType, includeDeleted, lang, }: { projectId: string; docType: D; includeDeleted?: boolean or undefined; lang?: string or undefined; }) => ReadHookResult<(Extract<{ schemaName: "deviceInfo"; name: string; deviceType: "device_type_unspecified" or ... 4 more ... or "UNRECOGN...` | Parameters: diff --git a/src/hooks/documents.ts b/src/hooks/documents.ts index 808c131..6280445 100644 --- a/src/hooks/documents.ts +++ b/src/hooks/documents.ts @@ -176,7 +176,7 @@ export function useManyDocs({ docType: D includeDeleted?: boolean lang?: string -}): ReadHookResult> { +}): ReadHookResult>> { const { data: projectApi } = useSingleProject({ projectId }) const { data, error, isRefetching } = useSuspenseQuery(