diff --git a/src/usePrismicClient.ts b/src/usePrismicClient.ts index 6c4519e..a23f72e 100644 --- a/src/usePrismicClient.ts +++ b/src/usePrismicClient.ts @@ -11,9 +11,11 @@ import { usePrismicContext } from "./usePrismicContext"; * * @returns The `@prismicio/client` instance provided to ``. */ -export const usePrismicClient = ( - explicitClient?: prismic.Client, -): prismic.Client => { +export const usePrismicClient = < + TDocuments extends prismic.PrismicDocument = prismic.PrismicDocument, +>( + explicitClient?: prismic.Client, +): prismic.Client => { const context = usePrismicContext(); const client = explicitClient || context?.client;