@prismicio/vue 3.1.3 → 3.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/components/PrismicEmbed.cjs.map +1 -1
- package/dist/components/PrismicEmbed.d.ts +57 -63
- package/dist/components/PrismicEmbed.js.map +1 -1
- package/dist/components/PrismicImage.cjs.map +1 -1
- package/dist/components/PrismicImage.d.ts +162 -162
- package/dist/components/PrismicImage.js.map +1 -1
- package/dist/components/PrismicLink.cjs.map +1 -1
- package/dist/components/PrismicLink.d.ts +191 -191
- package/dist/components/PrismicLink.js.map +1 -1
- package/dist/components/PrismicRichText.cjs +7 -2
- package/dist/components/PrismicRichText.cjs.map +1 -1
- package/dist/components/PrismicRichText.d.ts +160 -139
- package/dist/components/PrismicRichText.js +7 -2
- package/dist/components/PrismicRichText.js.map +1 -1
- package/dist/components/PrismicText.cjs.map +1 -1
- package/dist/components/PrismicText.d.ts +117 -117
- package/dist/components/PrismicText.js.map +1 -1
- package/dist/components/SliceZone.cjs.map +1 -1
- package/dist/components/SliceZone.d.ts +357 -359
- package/dist/components/SliceZone.js.map +1 -1
- package/dist/components/index.d.ts +12 -12
- package/dist/composables.d.ts +366 -366
- package/dist/createPrismic.cjs +3 -3
- package/dist/createPrismic.cjs.map +1 -1
- package/dist/createPrismic.d.ts +12 -12
- package/dist/createPrismic.js +3 -3
- package/dist/createPrismic.js.map +1 -1
- package/dist/globalExtensions.d.ts +11 -11
- package/dist/index.cjs +16 -16
- package/dist/index.d.ts +10 -10
- package/dist/index.js +3 -3
- package/dist/injectionSymbols.d.ts +9 -9
- package/dist/lib/__PRODUCTION__.d.ts +7 -7
- package/dist/lib/getSlots.d.ts +14 -14
- package/dist/lib/isInternalURL.d.ts +8 -8
- package/dist/lib/simplyResolveComponent.cjs.map +1 -1
- package/dist/lib/simplyResolveComponent.d.ts +12 -12
- package/dist/lib/simplyResolveComponent.js.map +1 -1
- package/dist/types.d.ts +366 -357
- package/dist/usePrismic.d.ts +21 -21
- package/dist/useStatefulPrismicClientMethod.d.ts +64 -64
- package/package.json +15 -15
- package/src/components/PrismicEmbed.ts +6 -2
- package/src/components/PrismicImage.ts +6 -2
- package/src/components/PrismicLink.ts +11 -5
- package/src/components/PrismicRichText.ts +30 -5
- package/src/components/PrismicText.ts +6 -2
- package/src/components/SliceZone.ts +8 -2
- package/src/createPrismic.ts +3 -6
- package/src/lib/simplyResolveComponent.ts +8 -2
- package/src/types.ts +15 -4
package/dist/composables.d.ts
CHANGED
|
@@ -1,366 +1,366 @@
|
|
|
1
|
-
import { PrismicDocument, Query } from "@prismicio/types";
|
|
2
|
-
import { ClientComposableReturnType, ComposableOnlyParameters } from "./useStatefulPrismicClientMethod";
|
|
3
|
-
/**
|
|
4
|
-
* A composable that queries content from the Prismic repository.
|
|
5
|
-
*
|
|
6
|
-
* @remarks
|
|
7
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
8
|
-
* `params.client`.
|
|
9
|
-
* @typeParam TDocument - Type of Prismic documents returned
|
|
10
|
-
*
|
|
11
|
-
* @param params - Parameters to filter, sort, and paginate results
|
|
12
|
-
*
|
|
13
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
14
|
-
*
|
|
15
|
-
* @see Underlying `@prismicio/client` method {@link Client.get}
|
|
16
|
-
*/
|
|
17
|
-
export declare const usePrismicDocuments: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
18
|
-
signal?: any;
|
|
19
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<Query<TDocument>>;
|
|
20
|
-
/**
|
|
21
|
-
* A composable that queries content from the Prismic repository and returns
|
|
22
|
-
* only the first result, if any.
|
|
23
|
-
*
|
|
24
|
-
* @remarks
|
|
25
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
26
|
-
* `params.client`.
|
|
27
|
-
* @typeParam TDocument - Type of the Prismic document returned
|
|
28
|
-
*
|
|
29
|
-
* @param params - Parameters to filter, sort, and paginate results
|
|
30
|
-
*
|
|
31
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
32
|
-
*
|
|
33
|
-
* @see Underlying `@prismicio/client` method {@link Client.getFirst}
|
|
34
|
-
*/
|
|
35
|
-
export declare const useFirstPrismicDocument: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
36
|
-
signal?: any;
|
|
37
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument>;
|
|
38
|
-
/**
|
|
39
|
-
* A composable that queries a document from the Prismic repository with a
|
|
40
|
-
* specific ID.
|
|
41
|
-
*
|
|
42
|
-
* @remarks
|
|
43
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
44
|
-
* `params.client`.
|
|
45
|
-
* @typeParam TDocument - Type of the Prismic document returned
|
|
46
|
-
*
|
|
47
|
-
* @param id - ID of the document
|
|
48
|
-
* @param params - Parameters to filter, sort, and paginate results
|
|
49
|
-
*
|
|
50
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
51
|
-
*
|
|
52
|
-
* @see Underlying `@prismicio/client` method {@link Client.getByID}
|
|
53
|
-
*/
|
|
54
|
-
export declare const usePrismicDocumentByID: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(id: string, params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
55
|
-
signal?: any;
|
|
56
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument>;
|
|
57
|
-
/**
|
|
58
|
-
* A composable that queries documents from the Prismic repository with specific
|
|
59
|
-
* IDs.
|
|
60
|
-
*
|
|
61
|
-
* @remarks
|
|
62
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
63
|
-
* `params.client`.
|
|
64
|
-
* @typeParam TDocument - Type of Prismic documents returned
|
|
65
|
-
*
|
|
66
|
-
* @param ids - A list of document IDs
|
|
67
|
-
* @param params - Parameters to filter, sort, and paginate results
|
|
68
|
-
*
|
|
69
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
70
|
-
*
|
|
71
|
-
* @see Underlying `@prismicio/client` method {@link Client.getByIDs}
|
|
72
|
-
*/
|
|
73
|
-
export declare const usePrismicDocumentsByIDs: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(ids: string[], params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
74
|
-
signal?: any;
|
|
75
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<Query<TDocument>>;
|
|
76
|
-
/**
|
|
77
|
-
* A composable that queries all documents from the Prismic repository with
|
|
78
|
-
* specific IDs.
|
|
79
|
-
*
|
|
80
|
-
* @remarks
|
|
81
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
82
|
-
* `params.client`.
|
|
83
|
-
* @typeParam TDocument - Type of Prismic documents returned
|
|
84
|
-
*
|
|
85
|
-
* @param ids - A list of document IDs
|
|
86
|
-
* @param params - Parameters to filter and sort results
|
|
87
|
-
*
|
|
88
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
89
|
-
*
|
|
90
|
-
* @see Underlying `@prismicio/client` method {@link Client.getAllByIDs}
|
|
91
|
-
*/
|
|
92
|
-
export declare const useAllPrismicDocumentsByIDs: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(ids: string[], params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
93
|
-
limit?: number | undefined;
|
|
94
|
-
} & {
|
|
95
|
-
signal?: any;
|
|
96
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument[]>;
|
|
97
|
-
/**
|
|
98
|
-
* A composable that queries a document from the Prismic repository with a
|
|
99
|
-
* specific UID and Custom Type.
|
|
100
|
-
*
|
|
101
|
-
* @remarks
|
|
102
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
103
|
-
* `params.client`.
|
|
104
|
-
* @typeParam TDocument - Type of the Prismic document returned
|
|
105
|
-
*
|
|
106
|
-
* @param documentType - The API ID of the document's Custom Type
|
|
107
|
-
* @param uid - UID of the document
|
|
108
|
-
* @param params - Parameters to filter, sort, and paginate results
|
|
109
|
-
*
|
|
110
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
111
|
-
*
|
|
112
|
-
* @see Underlying `@prismicio/client` method {@link Client.getByUID}
|
|
113
|
-
*/
|
|
114
|
-
export declare const usePrismicDocumentByUID: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(documentType: any, uid: string, params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
115
|
-
signal?: any;
|
|
116
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument>;
|
|
117
|
-
/**
|
|
118
|
-
* A composable that queries documents from the Prismic repository with specific
|
|
119
|
-
* UIDs.
|
|
120
|
-
*
|
|
121
|
-
* @remarks
|
|
122
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
123
|
-
* `params.client`.
|
|
124
|
-
* @typeParam TDocument - Type of Prismic documents returned
|
|
125
|
-
*
|
|
126
|
-
* @param documentType - The API ID of the document's Custom Type
|
|
127
|
-
* @param uids - A list of document UIDs
|
|
128
|
-
* @param params - Parameters to filter, sort, and paginate results
|
|
129
|
-
*
|
|
130
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
131
|
-
*
|
|
132
|
-
* @see Underlying `@prismicio/client` method {@link Client.getByIDs}
|
|
133
|
-
*/
|
|
134
|
-
export declare const usePrismicDocumentsByUIDs: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(documentType: any, uids: string[], params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
135
|
-
signal?: any;
|
|
136
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<Query<TDocument>>;
|
|
137
|
-
/**
|
|
138
|
-
* A composable that queries all documents from the Prismic repository with
|
|
139
|
-
* specific UIDs.
|
|
140
|
-
*
|
|
141
|
-
* @remarks
|
|
142
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
143
|
-
* `params.client`.
|
|
144
|
-
* @typeParam TDocument - Type of Prismic documents returned
|
|
145
|
-
*
|
|
146
|
-
* @param documentType - The API ID of the document's Custom Type
|
|
147
|
-
* @param uids - A list of document UIDs
|
|
148
|
-
* @param params - Parameters to filter and sort results
|
|
149
|
-
*
|
|
150
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
151
|
-
*
|
|
152
|
-
* @see Underlying `@prismicio/client` method {@link Client.getAllByIDs}
|
|
153
|
-
*/
|
|
154
|
-
export declare const useAllPrismicDocumentsByUIDs: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(documentType: any, ids: string[], params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
155
|
-
limit?: number | undefined;
|
|
156
|
-
} & {
|
|
157
|
-
signal?: any;
|
|
158
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument[]>;
|
|
159
|
-
/**
|
|
160
|
-
* A composable that queries a singleton document from the Prismic repository
|
|
161
|
-
* for a specific Custom Type.
|
|
162
|
-
*
|
|
163
|
-
* @remarks
|
|
164
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
165
|
-
* `params.client`.
|
|
166
|
-
* @typeParam TDocument - Type of the Prismic document returned
|
|
167
|
-
*
|
|
168
|
-
* @param documentType - The API ID of the singleton Custom Type
|
|
169
|
-
* @param params - Parameters to filter, sort, and paginate results
|
|
170
|
-
*
|
|
171
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
172
|
-
*
|
|
173
|
-
* @see Underlying `@prismicio/client` method {@link Client.getSingle}
|
|
174
|
-
*/
|
|
175
|
-
export declare const useSinglePrismicDocument: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(documentType: any, params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
176
|
-
signal?: any;
|
|
177
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument>;
|
|
178
|
-
/**
|
|
179
|
-
* A composable that queries documents from the Prismic repository for a
|
|
180
|
-
* specific Custom Type.
|
|
181
|
-
*
|
|
182
|
-
* @remarks
|
|
183
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
184
|
-
* `params.client`.
|
|
185
|
-
* @typeParam TDocument - Type of Prismic documents returned
|
|
186
|
-
*
|
|
187
|
-
* @param documentType - The API ID of the Custom Type
|
|
188
|
-
* @param params - Parameters to filter, sort, and paginate results
|
|
189
|
-
*
|
|
190
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
191
|
-
*
|
|
192
|
-
* @see Underlying `@prismicio/client` method {@link Client.getByType}
|
|
193
|
-
*/
|
|
194
|
-
export declare const usePrismicDocumentsByType: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(documentType: any, params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
195
|
-
signal?: any;
|
|
196
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<Query<TDocument>>;
|
|
197
|
-
/**
|
|
198
|
-
* A composable that queries all documents from the Prismic repository for a
|
|
199
|
-
* specific Custom Type.
|
|
200
|
-
*
|
|
201
|
-
* @remarks
|
|
202
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
203
|
-
* `params.client`.
|
|
204
|
-
* @typeParam TDocument - Type of Prismic documents returned
|
|
205
|
-
*
|
|
206
|
-
* @param documentType - The API ID of the Custom Type
|
|
207
|
-
* @param params - Parameters to filter and sort results
|
|
208
|
-
*
|
|
209
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
210
|
-
*
|
|
211
|
-
* @see Underlying `@prismicio/client` method {@link Client.getAllByType}
|
|
212
|
-
*/
|
|
213
|
-
export declare const useAllPrismicDocumentsByType: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(documentType: any, params?: (Partial<Omit<import("@prismicio/client").BuildQueryURLArgs, "page">> & {
|
|
214
|
-
limit?: number | undefined;
|
|
215
|
-
} & {
|
|
216
|
-
signal?: any;
|
|
217
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument[]>;
|
|
218
|
-
/**
|
|
219
|
-
* A composable that queries documents from the Prismic repository with a
|
|
220
|
-
* specific tag.
|
|
221
|
-
*
|
|
222
|
-
* @remarks
|
|
223
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
224
|
-
* `params.client`.
|
|
225
|
-
* @typeParam TDocument - Type of Prismic documents returned
|
|
226
|
-
*
|
|
227
|
-
* @param tag - The tag that must be included on a document
|
|
228
|
-
* @param params - Parameters to filter, sort, and paginate results
|
|
229
|
-
*
|
|
230
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
231
|
-
*
|
|
232
|
-
* @see Underlying `@prismicio/client` method {@link Client.getByTag}
|
|
233
|
-
*/
|
|
234
|
-
export declare const usePrismicDocumentsByTag: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(tag: string, params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
235
|
-
signal?: any;
|
|
236
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<Query<TDocument>>;
|
|
237
|
-
/**
|
|
238
|
-
* A composable that queries all documents from the Prismic repository with a
|
|
239
|
-
* specific tag.
|
|
240
|
-
*
|
|
241
|
-
* @remarks
|
|
242
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
243
|
-
* `params.client`.
|
|
244
|
-
* @typeParam TDocument - Type of Prismic documents returned
|
|
245
|
-
*
|
|
246
|
-
* @param tag - The tag that must be included on a document
|
|
247
|
-
* @param params - Parameters to filter and sort results
|
|
248
|
-
*
|
|
249
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
250
|
-
*
|
|
251
|
-
* @see Underlying `@prismicio/client` method {@link Client.getAllByTag}
|
|
252
|
-
*/
|
|
253
|
-
export declare const useAllPrismicDocumentsByTag: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(tag: string, params?: (Partial<Omit<import("@prismicio/client").BuildQueryURLArgs, "page">> & {
|
|
254
|
-
limit?: number | undefined;
|
|
255
|
-
} & {
|
|
256
|
-
signal?: any;
|
|
257
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument[]>;
|
|
258
|
-
/**
|
|
259
|
-
* A composable that queries documents from the Prismic repository with specific
|
|
260
|
-
* tags. A document must be tagged with all of the queried tags to be included.
|
|
261
|
-
*
|
|
262
|
-
* @remarks
|
|
263
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
264
|
-
* `params.client`.
|
|
265
|
-
* @typeParam TDocument - Type of Prismic documents returned
|
|
266
|
-
*
|
|
267
|
-
* @param tags - A list of tags that must be included on a document
|
|
268
|
-
* @param params - Parameters to filter, sort, and paginate results
|
|
269
|
-
*
|
|
270
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
271
|
-
*
|
|
272
|
-
* @see Underlying `@prismicio/client` method {@link Client.getByTags}
|
|
273
|
-
*/
|
|
274
|
-
export declare const usePrismicDocumentsByEveryTag: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(tags: string[], params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
275
|
-
signal?: any;
|
|
276
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<Query<TDocument>>;
|
|
277
|
-
/**
|
|
278
|
-
* A composable that queries all documents from the Prismic repository with
|
|
279
|
-
* specific tags. A document must be tagged with all of the queried tags to be
|
|
280
|
-
* included.
|
|
281
|
-
*
|
|
282
|
-
* @remarks
|
|
283
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
284
|
-
* `params.client`.
|
|
285
|
-
* @typeParam TDocument - Type of Prismic documents returned
|
|
286
|
-
*
|
|
287
|
-
* @param tags - A list of tags that must be included on a document
|
|
288
|
-
* @param params - Parameters to filter and sort results
|
|
289
|
-
*
|
|
290
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
291
|
-
*
|
|
292
|
-
* @see Underlying `@prismicio/client` method {@link Client.getAllByTags}
|
|
293
|
-
*/
|
|
294
|
-
export declare const useAllPrismicDocumentsByEveryTag: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(tags: string[], params?: (Partial<Omit<import("@prismicio/client").BuildQueryURLArgs, "page">> & {
|
|
295
|
-
limit?: number | undefined;
|
|
296
|
-
} & {
|
|
297
|
-
signal?: any;
|
|
298
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument[]>;
|
|
299
|
-
/**
|
|
300
|
-
* A composable that queries documents from the Prismic repository with specific
|
|
301
|
-
* tags. A document must be tagged with at least one of the queried tags to be
|
|
302
|
-
* included.
|
|
303
|
-
*
|
|
304
|
-
* @remarks
|
|
305
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
306
|
-
* `params.client`.
|
|
307
|
-
* @typeParam TDocument - Type of Prismic documents returned
|
|
308
|
-
*
|
|
309
|
-
* @param tags - A list of tags that must be included on a document
|
|
310
|
-
* @param params - Parameters to filter, sort, and paginate results
|
|
311
|
-
*
|
|
312
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
313
|
-
*
|
|
314
|
-
* @see Underlying `@prismicio/client` method {@link Client.getByTags}
|
|
315
|
-
*/
|
|
316
|
-
export declare const usePrismicDocumentsBySomeTags: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(tags: string[], params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
317
|
-
signal?: any;
|
|
318
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<Query<TDocument>>;
|
|
319
|
-
/**
|
|
320
|
-
* A composable that queries all documents from the Prismic repository with
|
|
321
|
-
* specific tags. A document must be tagged with at least one of the queried
|
|
322
|
-
* tags to be included.
|
|
323
|
-
*
|
|
324
|
-
* @remarks
|
|
325
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
326
|
-
* `params.client`.
|
|
327
|
-
* @typeParam TDocument - Type of Prismic documents returned
|
|
328
|
-
*
|
|
329
|
-
* @param tags - A list of tags that must be included on a document
|
|
330
|
-
* @param params - Parameters to filter and sort results
|
|
331
|
-
*
|
|
332
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
333
|
-
*
|
|
334
|
-
* @see Underlying `@prismicio/client` method {@link Client.getAllByTags}
|
|
335
|
-
*/
|
|
336
|
-
export declare const useAllPrismicDocumentsBySomeTags: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(tags: string[], params?: (Partial<Omit<import("@prismicio/client").BuildQueryURLArgs, "page">> & {
|
|
337
|
-
limit?: number | undefined;
|
|
338
|
-
} & {
|
|
339
|
-
signal?: any;
|
|
340
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument[]>;
|
|
341
|
-
/**
|
|
342
|
-
* **IMPORTANT**: Avoid using `dangerouslyUseAllPrismicDocuments` as it may be
|
|
343
|
-
* slower and require more resources than other composables. Prefer using other
|
|
344
|
-
* composables that filter by predicates such as
|
|
345
|
-
* `useAllPrismicDocumentsByType`.
|
|
346
|
-
*
|
|
347
|
-
* A composable that queries content from the Prismic repository and returns all
|
|
348
|
-
* matching content. If no predicates are provided, all documents will be
|
|
349
|
-
* fetched.
|
|
350
|
-
*
|
|
351
|
-
* @remarks
|
|
352
|
-
* An additional `@prismicio/client` instance can be provided at
|
|
353
|
-
* `params.client`.
|
|
354
|
-
* @typeParam TDocument - Type of Prismic documents returned
|
|
355
|
-
*
|
|
356
|
-
* @param params - Parameters to filter and sort results
|
|
357
|
-
*
|
|
358
|
-
* @returns The composable payload {@link ClientComposableReturnType}
|
|
359
|
-
*
|
|
360
|
-
* @see Underlying `@prismicio/client` method {@link Client.getAll}
|
|
361
|
-
*/
|
|
362
|
-
export declare const dangerouslyUseAllPrismicDocuments: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(params?: (Partial<Omit<import("@prismicio/client").BuildQueryURLArgs, "page">> & {
|
|
363
|
-
limit?: number | undefined;
|
|
364
|
-
} & {
|
|
365
|
-
signal?: any;
|
|
366
|
-
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument[]>;
|
|
1
|
+
import { PrismicDocument, Query } from "@prismicio/types";
|
|
2
|
+
import { ClientComposableReturnType, ComposableOnlyParameters } from "./useStatefulPrismicClientMethod";
|
|
3
|
+
/**
|
|
4
|
+
* A composable that queries content from the Prismic repository.
|
|
5
|
+
*
|
|
6
|
+
* @remarks
|
|
7
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
8
|
+
* `params.client`.
|
|
9
|
+
* @typeParam TDocument - Type of Prismic documents returned
|
|
10
|
+
*
|
|
11
|
+
* @param params - Parameters to filter, sort, and paginate results
|
|
12
|
+
*
|
|
13
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
14
|
+
*
|
|
15
|
+
* @see Underlying `@prismicio/client` method {@link Client.get}
|
|
16
|
+
*/
|
|
17
|
+
export declare const usePrismicDocuments: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
18
|
+
signal?: any;
|
|
19
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<Query<TDocument>>;
|
|
20
|
+
/**
|
|
21
|
+
* A composable that queries content from the Prismic repository and returns
|
|
22
|
+
* only the first result, if any.
|
|
23
|
+
*
|
|
24
|
+
* @remarks
|
|
25
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
26
|
+
* `params.client`.
|
|
27
|
+
* @typeParam TDocument - Type of the Prismic document returned
|
|
28
|
+
*
|
|
29
|
+
* @param params - Parameters to filter, sort, and paginate results
|
|
30
|
+
*
|
|
31
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
32
|
+
*
|
|
33
|
+
* @see Underlying `@prismicio/client` method {@link Client.getFirst}
|
|
34
|
+
*/
|
|
35
|
+
export declare const useFirstPrismicDocument: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
36
|
+
signal?: any;
|
|
37
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument>;
|
|
38
|
+
/**
|
|
39
|
+
* A composable that queries a document from the Prismic repository with a
|
|
40
|
+
* specific ID.
|
|
41
|
+
*
|
|
42
|
+
* @remarks
|
|
43
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
44
|
+
* `params.client`.
|
|
45
|
+
* @typeParam TDocument - Type of the Prismic document returned
|
|
46
|
+
*
|
|
47
|
+
* @param id - ID of the document
|
|
48
|
+
* @param params - Parameters to filter, sort, and paginate results
|
|
49
|
+
*
|
|
50
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
51
|
+
*
|
|
52
|
+
* @see Underlying `@prismicio/client` method {@link Client.getByID}
|
|
53
|
+
*/
|
|
54
|
+
export declare const usePrismicDocumentByID: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(id: string, params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
55
|
+
signal?: any;
|
|
56
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument>;
|
|
57
|
+
/**
|
|
58
|
+
* A composable that queries documents from the Prismic repository with specific
|
|
59
|
+
* IDs.
|
|
60
|
+
*
|
|
61
|
+
* @remarks
|
|
62
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
63
|
+
* `params.client`.
|
|
64
|
+
* @typeParam TDocument - Type of Prismic documents returned
|
|
65
|
+
*
|
|
66
|
+
* @param ids - A list of document IDs
|
|
67
|
+
* @param params - Parameters to filter, sort, and paginate results
|
|
68
|
+
*
|
|
69
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
70
|
+
*
|
|
71
|
+
* @see Underlying `@prismicio/client` method {@link Client.getByIDs}
|
|
72
|
+
*/
|
|
73
|
+
export declare const usePrismicDocumentsByIDs: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(ids: string[], params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
74
|
+
signal?: any;
|
|
75
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<Query<TDocument>>;
|
|
76
|
+
/**
|
|
77
|
+
* A composable that queries all documents from the Prismic repository with
|
|
78
|
+
* specific IDs.
|
|
79
|
+
*
|
|
80
|
+
* @remarks
|
|
81
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
82
|
+
* `params.client`.
|
|
83
|
+
* @typeParam TDocument - Type of Prismic documents returned
|
|
84
|
+
*
|
|
85
|
+
* @param ids - A list of document IDs
|
|
86
|
+
* @param params - Parameters to filter and sort results
|
|
87
|
+
*
|
|
88
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
89
|
+
*
|
|
90
|
+
* @see Underlying `@prismicio/client` method {@link Client.getAllByIDs}
|
|
91
|
+
*/
|
|
92
|
+
export declare const useAllPrismicDocumentsByIDs: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(ids: string[], params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
93
|
+
limit?: number | undefined;
|
|
94
|
+
} & {
|
|
95
|
+
signal?: any;
|
|
96
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument[]>;
|
|
97
|
+
/**
|
|
98
|
+
* A composable that queries a document from the Prismic repository with a
|
|
99
|
+
* specific UID and Custom Type.
|
|
100
|
+
*
|
|
101
|
+
* @remarks
|
|
102
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
103
|
+
* `params.client`.
|
|
104
|
+
* @typeParam TDocument - Type of the Prismic document returned
|
|
105
|
+
*
|
|
106
|
+
* @param documentType - The API ID of the document's Custom Type
|
|
107
|
+
* @param uid - UID of the document
|
|
108
|
+
* @param params - Parameters to filter, sort, and paginate results
|
|
109
|
+
*
|
|
110
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
111
|
+
*
|
|
112
|
+
* @see Underlying `@prismicio/client` method {@link Client.getByUID}
|
|
113
|
+
*/
|
|
114
|
+
export declare const usePrismicDocumentByUID: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(documentType: any, uid: string, params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
115
|
+
signal?: any;
|
|
116
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument>;
|
|
117
|
+
/**
|
|
118
|
+
* A composable that queries documents from the Prismic repository with specific
|
|
119
|
+
* UIDs.
|
|
120
|
+
*
|
|
121
|
+
* @remarks
|
|
122
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
123
|
+
* `params.client`.
|
|
124
|
+
* @typeParam TDocument - Type of Prismic documents returned
|
|
125
|
+
*
|
|
126
|
+
* @param documentType - The API ID of the document's Custom Type
|
|
127
|
+
* @param uids - A list of document UIDs
|
|
128
|
+
* @param params - Parameters to filter, sort, and paginate results
|
|
129
|
+
*
|
|
130
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
131
|
+
*
|
|
132
|
+
* @see Underlying `@prismicio/client` method {@link Client.getByIDs}
|
|
133
|
+
*/
|
|
134
|
+
export declare const usePrismicDocumentsByUIDs: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(documentType: any, uids: string[], params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
135
|
+
signal?: any;
|
|
136
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<Query<TDocument>>;
|
|
137
|
+
/**
|
|
138
|
+
* A composable that queries all documents from the Prismic repository with
|
|
139
|
+
* specific UIDs.
|
|
140
|
+
*
|
|
141
|
+
* @remarks
|
|
142
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
143
|
+
* `params.client`.
|
|
144
|
+
* @typeParam TDocument - Type of Prismic documents returned
|
|
145
|
+
*
|
|
146
|
+
* @param documentType - The API ID of the document's Custom Type
|
|
147
|
+
* @param uids - A list of document UIDs
|
|
148
|
+
* @param params - Parameters to filter and sort results
|
|
149
|
+
*
|
|
150
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
151
|
+
*
|
|
152
|
+
* @see Underlying `@prismicio/client` method {@link Client.getAllByIDs}
|
|
153
|
+
*/
|
|
154
|
+
export declare const useAllPrismicDocumentsByUIDs: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(documentType: any, ids: string[], params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
155
|
+
limit?: number | undefined;
|
|
156
|
+
} & {
|
|
157
|
+
signal?: any;
|
|
158
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument[]>;
|
|
159
|
+
/**
|
|
160
|
+
* A composable that queries a singleton document from the Prismic repository
|
|
161
|
+
* for a specific Custom Type.
|
|
162
|
+
*
|
|
163
|
+
* @remarks
|
|
164
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
165
|
+
* `params.client`.
|
|
166
|
+
* @typeParam TDocument - Type of the Prismic document returned
|
|
167
|
+
*
|
|
168
|
+
* @param documentType - The API ID of the singleton Custom Type
|
|
169
|
+
* @param params - Parameters to filter, sort, and paginate results
|
|
170
|
+
*
|
|
171
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
172
|
+
*
|
|
173
|
+
* @see Underlying `@prismicio/client` method {@link Client.getSingle}
|
|
174
|
+
*/
|
|
175
|
+
export declare const useSinglePrismicDocument: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(documentType: any, params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
176
|
+
signal?: any;
|
|
177
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument>;
|
|
178
|
+
/**
|
|
179
|
+
* A composable that queries documents from the Prismic repository for a
|
|
180
|
+
* specific Custom Type.
|
|
181
|
+
*
|
|
182
|
+
* @remarks
|
|
183
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
184
|
+
* `params.client`.
|
|
185
|
+
* @typeParam TDocument - Type of Prismic documents returned
|
|
186
|
+
*
|
|
187
|
+
* @param documentType - The API ID of the Custom Type
|
|
188
|
+
* @param params - Parameters to filter, sort, and paginate results
|
|
189
|
+
*
|
|
190
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
191
|
+
*
|
|
192
|
+
* @see Underlying `@prismicio/client` method {@link Client.getByType}
|
|
193
|
+
*/
|
|
194
|
+
export declare const usePrismicDocumentsByType: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(documentType: any, params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
195
|
+
signal?: any;
|
|
196
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<Query<TDocument>>;
|
|
197
|
+
/**
|
|
198
|
+
* A composable that queries all documents from the Prismic repository for a
|
|
199
|
+
* specific Custom Type.
|
|
200
|
+
*
|
|
201
|
+
* @remarks
|
|
202
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
203
|
+
* `params.client`.
|
|
204
|
+
* @typeParam TDocument - Type of Prismic documents returned
|
|
205
|
+
*
|
|
206
|
+
* @param documentType - The API ID of the Custom Type
|
|
207
|
+
* @param params - Parameters to filter and sort results
|
|
208
|
+
*
|
|
209
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
210
|
+
*
|
|
211
|
+
* @see Underlying `@prismicio/client` method {@link Client.getAllByType}
|
|
212
|
+
*/
|
|
213
|
+
export declare const useAllPrismicDocumentsByType: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(documentType: any, params?: (Partial<Omit<import("@prismicio/client").BuildQueryURLArgs, "page">> & {
|
|
214
|
+
limit?: number | undefined;
|
|
215
|
+
} & {
|
|
216
|
+
signal?: any;
|
|
217
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument[]>;
|
|
218
|
+
/**
|
|
219
|
+
* A composable that queries documents from the Prismic repository with a
|
|
220
|
+
* specific tag.
|
|
221
|
+
*
|
|
222
|
+
* @remarks
|
|
223
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
224
|
+
* `params.client`.
|
|
225
|
+
* @typeParam TDocument - Type of Prismic documents returned
|
|
226
|
+
*
|
|
227
|
+
* @param tag - The tag that must be included on a document
|
|
228
|
+
* @param params - Parameters to filter, sort, and paginate results
|
|
229
|
+
*
|
|
230
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
231
|
+
*
|
|
232
|
+
* @see Underlying `@prismicio/client` method {@link Client.getByTag}
|
|
233
|
+
*/
|
|
234
|
+
export declare const usePrismicDocumentsByTag: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(tag: string, params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
235
|
+
signal?: any;
|
|
236
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<Query<TDocument>>;
|
|
237
|
+
/**
|
|
238
|
+
* A composable that queries all documents from the Prismic repository with a
|
|
239
|
+
* specific tag.
|
|
240
|
+
*
|
|
241
|
+
* @remarks
|
|
242
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
243
|
+
* `params.client`.
|
|
244
|
+
* @typeParam TDocument - Type of Prismic documents returned
|
|
245
|
+
*
|
|
246
|
+
* @param tag - The tag that must be included on a document
|
|
247
|
+
* @param params - Parameters to filter and sort results
|
|
248
|
+
*
|
|
249
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
250
|
+
*
|
|
251
|
+
* @see Underlying `@prismicio/client` method {@link Client.getAllByTag}
|
|
252
|
+
*/
|
|
253
|
+
export declare const useAllPrismicDocumentsByTag: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(tag: string, params?: (Partial<Omit<import("@prismicio/client").BuildQueryURLArgs, "page">> & {
|
|
254
|
+
limit?: number | undefined;
|
|
255
|
+
} & {
|
|
256
|
+
signal?: any;
|
|
257
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument[]>;
|
|
258
|
+
/**
|
|
259
|
+
* A composable that queries documents from the Prismic repository with specific
|
|
260
|
+
* tags. A document must be tagged with all of the queried tags to be included.
|
|
261
|
+
*
|
|
262
|
+
* @remarks
|
|
263
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
264
|
+
* `params.client`.
|
|
265
|
+
* @typeParam TDocument - Type of Prismic documents returned
|
|
266
|
+
*
|
|
267
|
+
* @param tags - A list of tags that must be included on a document
|
|
268
|
+
* @param params - Parameters to filter, sort, and paginate results
|
|
269
|
+
*
|
|
270
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
271
|
+
*
|
|
272
|
+
* @see Underlying `@prismicio/client` method {@link Client.getByTags}
|
|
273
|
+
*/
|
|
274
|
+
export declare const usePrismicDocumentsByEveryTag: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(tags: string[], params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
275
|
+
signal?: any;
|
|
276
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<Query<TDocument>>;
|
|
277
|
+
/**
|
|
278
|
+
* A composable that queries all documents from the Prismic repository with
|
|
279
|
+
* specific tags. A document must be tagged with all of the queried tags to be
|
|
280
|
+
* included.
|
|
281
|
+
*
|
|
282
|
+
* @remarks
|
|
283
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
284
|
+
* `params.client`.
|
|
285
|
+
* @typeParam TDocument - Type of Prismic documents returned
|
|
286
|
+
*
|
|
287
|
+
* @param tags - A list of tags that must be included on a document
|
|
288
|
+
* @param params - Parameters to filter and sort results
|
|
289
|
+
*
|
|
290
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
291
|
+
*
|
|
292
|
+
* @see Underlying `@prismicio/client` method {@link Client.getAllByTags}
|
|
293
|
+
*/
|
|
294
|
+
export declare const useAllPrismicDocumentsByEveryTag: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(tags: string[], params?: (Partial<Omit<import("@prismicio/client").BuildQueryURLArgs, "page">> & {
|
|
295
|
+
limit?: number | undefined;
|
|
296
|
+
} & {
|
|
297
|
+
signal?: any;
|
|
298
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument[]>;
|
|
299
|
+
/**
|
|
300
|
+
* A composable that queries documents from the Prismic repository with specific
|
|
301
|
+
* tags. A document must be tagged with at least one of the queried tags to be
|
|
302
|
+
* included.
|
|
303
|
+
*
|
|
304
|
+
* @remarks
|
|
305
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
306
|
+
* `params.client`.
|
|
307
|
+
* @typeParam TDocument - Type of Prismic documents returned
|
|
308
|
+
*
|
|
309
|
+
* @param tags - A list of tags that must be included on a document
|
|
310
|
+
* @param params - Parameters to filter, sort, and paginate results
|
|
311
|
+
*
|
|
312
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
313
|
+
*
|
|
314
|
+
* @see Underlying `@prismicio/client` method {@link Client.getByTags}
|
|
315
|
+
*/
|
|
316
|
+
export declare const usePrismicDocumentsBySomeTags: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(tags: string[], params?: (Partial<import("@prismicio/client").BuildQueryURLArgs> & {
|
|
317
|
+
signal?: any;
|
|
318
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<Query<TDocument>>;
|
|
319
|
+
/**
|
|
320
|
+
* A composable that queries all documents from the Prismic repository with
|
|
321
|
+
* specific tags. A document must be tagged with at least one of the queried
|
|
322
|
+
* tags to be included.
|
|
323
|
+
*
|
|
324
|
+
* @remarks
|
|
325
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
326
|
+
* `params.client`.
|
|
327
|
+
* @typeParam TDocument - Type of Prismic documents returned
|
|
328
|
+
*
|
|
329
|
+
* @param tags - A list of tags that must be included on a document
|
|
330
|
+
* @param params - Parameters to filter and sort results
|
|
331
|
+
*
|
|
332
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
333
|
+
*
|
|
334
|
+
* @see Underlying `@prismicio/client` method {@link Client.getAllByTags}
|
|
335
|
+
*/
|
|
336
|
+
export declare const useAllPrismicDocumentsBySomeTags: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(tags: string[], params?: (Partial<Omit<import("@prismicio/client").BuildQueryURLArgs, "page">> & {
|
|
337
|
+
limit?: number | undefined;
|
|
338
|
+
} & {
|
|
339
|
+
signal?: any;
|
|
340
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument[]>;
|
|
341
|
+
/**
|
|
342
|
+
* **IMPORTANT**: Avoid using `dangerouslyUseAllPrismicDocuments` as it may be
|
|
343
|
+
* slower and require more resources than other composables. Prefer using other
|
|
344
|
+
* composables that filter by predicates such as
|
|
345
|
+
* `useAllPrismicDocumentsByType`.
|
|
346
|
+
*
|
|
347
|
+
* A composable that queries content from the Prismic repository and returns all
|
|
348
|
+
* matching content. If no predicates are provided, all documents will be
|
|
349
|
+
* fetched.
|
|
350
|
+
*
|
|
351
|
+
* @remarks
|
|
352
|
+
* An additional `@prismicio/client` instance can be provided at
|
|
353
|
+
* `params.client`.
|
|
354
|
+
* @typeParam TDocument - Type of Prismic documents returned
|
|
355
|
+
*
|
|
356
|
+
* @param params - Parameters to filter and sort results
|
|
357
|
+
*
|
|
358
|
+
* @returns The composable payload {@link ClientComposableReturnType}
|
|
359
|
+
*
|
|
360
|
+
* @see Underlying `@prismicio/client` method {@link Client.getAll}
|
|
361
|
+
*/
|
|
362
|
+
export declare const dangerouslyUseAllPrismicDocuments: <TDocument extends PrismicDocument<Record<string, any>, string, string>>(params?: (Partial<Omit<import("@prismicio/client").BuildQueryURLArgs, "page">> & {
|
|
363
|
+
limit?: number | undefined;
|
|
364
|
+
} & {
|
|
365
|
+
signal?: any;
|
|
366
|
+
} & ComposableOnlyParameters) | undefined) => ClientComposableReturnType<TDocument[]>;
|