astro 4.13.4 → 4.14.1
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/components/Code.astro +9 -0
- package/dist/@types/astro.d.ts +249 -1
- package/dist/actions/consts.d.ts +1 -1
- package/dist/actions/consts.js +1 -1
- package/dist/actions/index.js +12 -21
- package/dist/assets/endpoint/node.js +1 -1
- package/dist/assets/utils/resolveImports.d.ts +9 -0
- package/dist/assets/utils/resolveImports.js +22 -0
- package/dist/cli/add/index.d.ts +2 -2
- package/dist/cli/add/index.js +2 -2
- package/dist/cli/build/index.d.ts +2 -2
- package/dist/cli/build/index.js +5 -1
- package/dist/cli/check/index.d.ts +2 -2
- package/dist/cli/check/index.js +5 -2
- package/dist/cli/db/index.d.ts +4 -3
- package/dist/cli/db/index.js +10 -3
- package/dist/cli/dev/index.d.ts +2 -2
- package/dist/cli/dev/index.js +1 -0
- package/dist/cli/docs/index.d.ts +2 -2
- package/dist/cli/flags.d.ts +3 -1
- package/dist/cli/flags.js +2 -1
- package/dist/cli/index.d.ts +1 -1
- package/dist/cli/index.js +26 -13
- package/dist/cli/info/index.d.ts +2 -2
- package/dist/cli/preferences/index.d.ts +2 -2
- package/dist/cli/preferences/index.js +1 -1
- package/dist/cli/preview/index.d.ts +2 -2
- package/dist/cli/sync/index.d.ts +2 -2
- package/dist/cli/sync/index.js +5 -2
- package/dist/cli/telemetry/index.d.ts +2 -2
- package/dist/content/consts.d.ts +16 -2
- package/dist/content/consts.js +32 -2
- package/dist/content/content-layer.d.ts +40 -0
- package/dist/content/content-layer.js +253 -0
- package/dist/content/data-store.d.ts +54 -0
- package/dist/content/data-store.js +72 -0
- package/dist/content/loaders/file.d.ts +7 -0
- package/dist/content/loaders/file.js +72 -0
- package/dist/content/loaders/glob.d.ts +25 -0
- package/dist/content/loaders/glob.js +218 -0
- package/dist/content/loaders/index.d.ts +3 -0
- package/dist/content/loaders/index.js +7 -0
- package/dist/content/loaders/types.d.ts +36 -0
- package/dist/content/loaders/types.js +0 -0
- package/dist/content/mutable-data-store.d.ts +77 -0
- package/dist/content/mutable-data-store.js +269 -0
- package/dist/content/runtime.d.ts +46 -8
- package/dist/content/runtime.js +225 -31
- package/dist/content/types-generator.js +123 -35
- package/dist/content/utils.d.ts +307 -2
- package/dist/content/utils.js +101 -7
- package/dist/content/vite-plugin-content-assets.js +9 -1
- package/dist/content/vite-plugin-content-virtual-mod.js +94 -2
- package/dist/core/build/index.js +14 -7
- package/dist/core/build/plugins/plugin-ssr.js +32 -4
- package/dist/core/config/config.d.ts +2 -5
- package/dist/core/config/config.js +0 -12
- package/dist/core/config/index.d.ts +1 -1
- package/dist/core/config/index.js +0 -2
- package/dist/core/config/schema.d.ts +34 -0
- package/dist/core/config/schema.js +6 -2
- package/dist/core/config/settings.js +5 -3
- package/dist/core/constants.js +1 -1
- package/dist/core/create-vite.js +1 -1
- package/dist/core/dev/container.js +2 -1
- package/dist/core/dev/dev.js +33 -3
- package/dist/core/dev/restart.js +25 -10
- package/dist/core/errors/errors-data.d.ts +21 -0
- package/dist/core/errors/errors-data.js +13 -0
- package/dist/core/index.js +1 -1
- package/dist/core/logger/vite.js +1 -1
- package/dist/core/messages.js +2 -2
- package/dist/core/preview/static-preview-server.js +1 -1
- package/dist/core/routing/manifest/create.js +1 -1
- package/dist/core/sync/constants.d.ts +1 -0
- package/dist/core/sync/constants.js +4 -0
- package/dist/core/sync/index.d.ts +12 -4
- package/dist/core/sync/index.js +54 -24
- package/dist/core/sync/write-files.d.ts +4 -0
- package/dist/core/sync/write-files.js +69 -0
- package/dist/core/util.js +1 -1
- package/dist/env/sync.js +6 -4
- package/dist/integrations/hooks.d.ts +7 -1
- package/dist/integrations/hooks.js +54 -0
- package/dist/preferences/index.d.ts +1 -1
- package/dist/preferences/index.js +2 -2
- package/dist/runtime/server/render/server-islands.js +6 -4
- package/dist/vite-plugin-astro-server/response.js +1 -1
- package/dist/vite-plugin-env/index.d.ts +3 -1
- package/dist/vite-plugin-env/index.js +11 -1
- package/dist/vite-plugin-markdown/content-entry-type.js +25 -2
- package/dist/vite-plugin-scanner/index.js +15 -5
- package/package.json +10 -5
- package/templates/content/module.mjs +6 -1
- package/templates/content/types.d.ts +18 -5
- package/types/content.d.ts +34 -1
- package/dist/core/sync/setup-env-ts.d.ts +0 -8
- package/dist/core/sync/setup-env-ts.js +0 -79
|
@@ -0,0 +1,269 @@
|
|
|
1
|
+
import { promises as fs, existsSync } from "node:fs";
|
|
2
|
+
import * as devalue from "devalue";
|
|
3
|
+
import { imageSrcToImportId, importIdToSymbolName } from "../assets/utils/resolveImports.js";
|
|
4
|
+
import { AstroError, AstroErrorData } from "../core/errors/index.js";
|
|
5
|
+
import { DataStore } from "./data-store.js";
|
|
6
|
+
import { contentModuleToId } from "./utils.js";
|
|
7
|
+
const SAVE_DEBOUNCE_MS = 500;
|
|
8
|
+
class MutableDataStore extends DataStore {
|
|
9
|
+
#file;
|
|
10
|
+
#assetsFile;
|
|
11
|
+
#modulesFile;
|
|
12
|
+
#saveTimeout;
|
|
13
|
+
#assetsSaveTimeout;
|
|
14
|
+
#modulesSaveTimeout;
|
|
15
|
+
#dirty = false;
|
|
16
|
+
#assetsDirty = false;
|
|
17
|
+
#modulesDirty = false;
|
|
18
|
+
#assetImports = /* @__PURE__ */ new Set();
|
|
19
|
+
#moduleImports = /* @__PURE__ */ new Map();
|
|
20
|
+
set(collectionName, key, value) {
|
|
21
|
+
const collection = this._collections.get(collectionName) ?? /* @__PURE__ */ new Map();
|
|
22
|
+
collection.set(String(key), value);
|
|
23
|
+
this._collections.set(collectionName, collection);
|
|
24
|
+
this.#saveToDiskDebounced();
|
|
25
|
+
}
|
|
26
|
+
delete(collectionName, key) {
|
|
27
|
+
const collection = this._collections.get(collectionName);
|
|
28
|
+
if (collection) {
|
|
29
|
+
collection.delete(String(key));
|
|
30
|
+
this.#saveToDiskDebounced();
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
clear(collectionName) {
|
|
34
|
+
this._collections.delete(collectionName);
|
|
35
|
+
this.#saveToDiskDebounced();
|
|
36
|
+
}
|
|
37
|
+
clearAll() {
|
|
38
|
+
this._collections.clear();
|
|
39
|
+
this.#saveToDiskDebounced();
|
|
40
|
+
}
|
|
41
|
+
addAssetImport(assetImport, filePath) {
|
|
42
|
+
const id = imageSrcToImportId(assetImport, filePath);
|
|
43
|
+
if (id) {
|
|
44
|
+
this.#assetImports.add(id);
|
|
45
|
+
this.#writeAssetsImportsDebounced();
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
addAssetImports(assets, filePath) {
|
|
49
|
+
assets.forEach((asset) => this.addAssetImport(asset, filePath));
|
|
50
|
+
}
|
|
51
|
+
addModuleImport(fileName) {
|
|
52
|
+
const id = contentModuleToId(fileName);
|
|
53
|
+
if (id) {
|
|
54
|
+
this.#moduleImports.set(fileName, id);
|
|
55
|
+
this.#writeModulesImportsDebounced();
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
async writeAssetImports(filePath) {
|
|
59
|
+
this.#assetsFile = filePath;
|
|
60
|
+
if (this.#assetImports.size === 0) {
|
|
61
|
+
try {
|
|
62
|
+
await fs.writeFile(filePath, "export default new Map();");
|
|
63
|
+
} catch (err) {
|
|
64
|
+
throw new AstroError(AstroErrorData.UnknownFilesystemError, { cause: err });
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
if (!this.#assetsDirty && existsSync(filePath)) {
|
|
68
|
+
return;
|
|
69
|
+
}
|
|
70
|
+
const imports = [];
|
|
71
|
+
const exports = [];
|
|
72
|
+
this.#assetImports.forEach((id) => {
|
|
73
|
+
const symbol = importIdToSymbolName(id);
|
|
74
|
+
imports.push(`import ${symbol} from '${id}';`);
|
|
75
|
+
exports.push(`[${JSON.stringify(id)}, ${symbol}]`);
|
|
76
|
+
});
|
|
77
|
+
const code = (
|
|
78
|
+
/* js */
|
|
79
|
+
`
|
|
80
|
+
${imports.join("\n")}
|
|
81
|
+
export default new Map([${exports.join(", ")}]);
|
|
82
|
+
`
|
|
83
|
+
);
|
|
84
|
+
try {
|
|
85
|
+
await fs.writeFile(filePath, code);
|
|
86
|
+
} catch (err) {
|
|
87
|
+
throw new AstroError(AstroErrorData.UnknownFilesystemError, { cause: err });
|
|
88
|
+
}
|
|
89
|
+
this.#assetsDirty = false;
|
|
90
|
+
}
|
|
91
|
+
async writeModuleImports(filePath) {
|
|
92
|
+
this.#modulesFile = filePath;
|
|
93
|
+
if (this.#moduleImports.size === 0) {
|
|
94
|
+
try {
|
|
95
|
+
await fs.writeFile(filePath, "export default new Map();");
|
|
96
|
+
} catch (err) {
|
|
97
|
+
throw new AstroError(AstroErrorData.UnknownFilesystemError, { cause: err });
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
if (!this.#modulesDirty && existsSync(filePath)) {
|
|
101
|
+
return;
|
|
102
|
+
}
|
|
103
|
+
const lines = [];
|
|
104
|
+
for (const [fileName, specifier] of this.#moduleImports) {
|
|
105
|
+
lines.push(`['${fileName}', () => import('${specifier}')]`);
|
|
106
|
+
}
|
|
107
|
+
const code = `
|
|
108
|
+
export default new Map([
|
|
109
|
+
${lines.join(",\n")}]);
|
|
110
|
+
`;
|
|
111
|
+
try {
|
|
112
|
+
await fs.writeFile(filePath, code);
|
|
113
|
+
} catch (err) {
|
|
114
|
+
throw new AstroError(AstroErrorData.UnknownFilesystemError, { cause: err });
|
|
115
|
+
}
|
|
116
|
+
this.#modulesDirty = false;
|
|
117
|
+
}
|
|
118
|
+
#writeAssetsImportsDebounced() {
|
|
119
|
+
this.#assetsDirty = true;
|
|
120
|
+
if (this.#assetsFile) {
|
|
121
|
+
if (this.#assetsSaveTimeout) {
|
|
122
|
+
clearTimeout(this.#assetsSaveTimeout);
|
|
123
|
+
}
|
|
124
|
+
this.#assetsSaveTimeout = setTimeout(() => {
|
|
125
|
+
this.#assetsSaveTimeout = void 0;
|
|
126
|
+
this.writeAssetImports(this.#assetsFile);
|
|
127
|
+
}, SAVE_DEBOUNCE_MS);
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
#writeModulesImportsDebounced() {
|
|
131
|
+
this.#modulesDirty = true;
|
|
132
|
+
if (this.#modulesFile) {
|
|
133
|
+
if (this.#modulesSaveTimeout) {
|
|
134
|
+
clearTimeout(this.#modulesSaveTimeout);
|
|
135
|
+
}
|
|
136
|
+
this.#modulesSaveTimeout = setTimeout(() => {
|
|
137
|
+
this.#modulesSaveTimeout = void 0;
|
|
138
|
+
this.writeModuleImports(this.#modulesFile);
|
|
139
|
+
}, SAVE_DEBOUNCE_MS);
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
#saveToDiskDebounced() {
|
|
143
|
+
this.#dirty = true;
|
|
144
|
+
if (this.#file) {
|
|
145
|
+
if (this.#saveTimeout) {
|
|
146
|
+
clearTimeout(this.#saveTimeout);
|
|
147
|
+
}
|
|
148
|
+
this.#saveTimeout = setTimeout(() => {
|
|
149
|
+
this.#saveTimeout = void 0;
|
|
150
|
+
this.writeToDisk(this.#file);
|
|
151
|
+
}, SAVE_DEBOUNCE_MS);
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
scopedStore(collectionName) {
|
|
155
|
+
return {
|
|
156
|
+
get: (key) => this.get(collectionName, key),
|
|
157
|
+
entries: () => this.entries(collectionName),
|
|
158
|
+
values: () => this.values(collectionName),
|
|
159
|
+
keys: () => this.keys(collectionName),
|
|
160
|
+
set: ({ id: key, data, body, filePath, deferredRender, digest, rendered }) => {
|
|
161
|
+
if (!key) {
|
|
162
|
+
throw new Error(`ID must be a non-empty string`);
|
|
163
|
+
}
|
|
164
|
+
const id = String(key);
|
|
165
|
+
if (digest) {
|
|
166
|
+
const existing = this.get(collectionName, id);
|
|
167
|
+
if (existing && existing.digest === digest) {
|
|
168
|
+
return false;
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
const entry = {
|
|
172
|
+
id,
|
|
173
|
+
data
|
|
174
|
+
};
|
|
175
|
+
if (body) {
|
|
176
|
+
entry.body = body;
|
|
177
|
+
}
|
|
178
|
+
if (filePath) {
|
|
179
|
+
if (filePath.startsWith("/")) {
|
|
180
|
+
throw new Error(`File path must be relative to the site root. Got: ${filePath}`);
|
|
181
|
+
}
|
|
182
|
+
entry.filePath = filePath;
|
|
183
|
+
}
|
|
184
|
+
if (digest) {
|
|
185
|
+
entry.digest = digest;
|
|
186
|
+
}
|
|
187
|
+
if (rendered) {
|
|
188
|
+
entry.rendered = rendered;
|
|
189
|
+
}
|
|
190
|
+
if (deferredRender) {
|
|
191
|
+
entry.deferredRender = deferredRender;
|
|
192
|
+
if (filePath) {
|
|
193
|
+
this.addModuleImport(filePath);
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
this.set(collectionName, id, entry);
|
|
197
|
+
return true;
|
|
198
|
+
},
|
|
199
|
+
delete: (key) => this.delete(collectionName, key),
|
|
200
|
+
clear: () => this.clear(collectionName),
|
|
201
|
+
has: (key) => this.has(collectionName, key),
|
|
202
|
+
addAssetImport: (assetImport, fileName) => this.addAssetImport(assetImport, fileName),
|
|
203
|
+
addAssetImports: (assets, fileName) => this.addAssetImports(assets, fileName),
|
|
204
|
+
addModuleImport: (fileName) => this.addModuleImport(fileName)
|
|
205
|
+
};
|
|
206
|
+
}
|
|
207
|
+
/**
|
|
208
|
+
* Returns a MetaStore for a given collection, or if no collection is provided, the default meta collection.
|
|
209
|
+
*/
|
|
210
|
+
metaStore(collectionName = ":meta") {
|
|
211
|
+
const collectionKey = `meta:${collectionName}`;
|
|
212
|
+
return {
|
|
213
|
+
get: (key) => this.get(collectionKey, key),
|
|
214
|
+
set: (key, data) => this.set(collectionKey, key, data),
|
|
215
|
+
delete: (key) => this.delete(collectionKey, key),
|
|
216
|
+
has: (key) => this.has(collectionKey, key)
|
|
217
|
+
};
|
|
218
|
+
}
|
|
219
|
+
toString() {
|
|
220
|
+
return devalue.stringify(this._collections);
|
|
221
|
+
}
|
|
222
|
+
async writeToDisk(filePath) {
|
|
223
|
+
if (!this.#dirty) {
|
|
224
|
+
return;
|
|
225
|
+
}
|
|
226
|
+
try {
|
|
227
|
+
await fs.writeFile(filePath, this.toString());
|
|
228
|
+
this.#file = filePath;
|
|
229
|
+
this.#dirty = false;
|
|
230
|
+
} catch (err) {
|
|
231
|
+
throw new AstroError(AstroErrorData.UnknownFilesystemError, { cause: err });
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
/**
|
|
235
|
+
* Attempts to load a MutableDataStore from the virtual module.
|
|
236
|
+
* This only works in Vite.
|
|
237
|
+
*/
|
|
238
|
+
static async fromModule() {
|
|
239
|
+
try {
|
|
240
|
+
const data = await import("astro:data-layer-content");
|
|
241
|
+
const map = devalue.unflatten(data.default);
|
|
242
|
+
return MutableDataStore.fromMap(map);
|
|
243
|
+
} catch {
|
|
244
|
+
}
|
|
245
|
+
return new MutableDataStore();
|
|
246
|
+
}
|
|
247
|
+
static async fromMap(data) {
|
|
248
|
+
const store = new MutableDataStore();
|
|
249
|
+
store._collections = data;
|
|
250
|
+
return store;
|
|
251
|
+
}
|
|
252
|
+
static async fromString(data) {
|
|
253
|
+
const map = devalue.parse(data);
|
|
254
|
+
return MutableDataStore.fromMap(map);
|
|
255
|
+
}
|
|
256
|
+
static async fromFile(filePath) {
|
|
257
|
+
try {
|
|
258
|
+
if (existsSync(filePath)) {
|
|
259
|
+
const data = await fs.readFile(filePath, "utf-8");
|
|
260
|
+
return MutableDataStore.fromString(data);
|
|
261
|
+
}
|
|
262
|
+
} catch {
|
|
263
|
+
}
|
|
264
|
+
return new MutableDataStore();
|
|
265
|
+
}
|
|
266
|
+
}
|
|
267
|
+
export {
|
|
268
|
+
MutableDataStore
|
|
269
|
+
};
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import type { MarkdownHeading } from '@astrojs/markdown-remark';
|
|
2
|
+
import { z } from 'zod';
|
|
2
3
|
import { type AstroComponentFactory } from '../runtime/server/index.js';
|
|
4
|
+
import { type DataEntry } from './data-store.js';
|
|
3
5
|
import type { ContentLookupMap } from './utils.js';
|
|
4
6
|
type LazyImport = () => Promise<any>;
|
|
5
7
|
type GlobResult = Record<string, LazyImport>;
|
|
@@ -16,9 +18,10 @@ export declare function createGetCollection({ contentCollectionToEntryMap, dataC
|
|
|
16
18
|
getRenderEntryImport: GetEntryImport;
|
|
17
19
|
cacheEntriesByCollection: Map<string, any[]>;
|
|
18
20
|
}): (collection: string, filter?: (entry: any) => unknown) => Promise<any[]>;
|
|
19
|
-
export declare function createGetEntryBySlug({ getEntryImport, getRenderEntryImport, }: {
|
|
21
|
+
export declare function createGetEntryBySlug({ getEntryImport, getRenderEntryImport, collectionNames, }: {
|
|
20
22
|
getEntryImport: GetEntryImport;
|
|
21
23
|
getRenderEntryImport: GetEntryImport;
|
|
24
|
+
collectionNames: Set<string>;
|
|
22
25
|
}): (collection: string, slug: string) => Promise<{
|
|
23
26
|
id: any;
|
|
24
27
|
slug: any;
|
|
@@ -27,13 +30,14 @@ export declare function createGetEntryBySlug({ getEntryImport, getRenderEntryImp
|
|
|
27
30
|
data: any;
|
|
28
31
|
render(): Promise<RenderResult>;
|
|
29
32
|
} | undefined>;
|
|
30
|
-
export declare function createGetDataEntryById({ getEntryImport }: {
|
|
33
|
+
export declare function createGetDataEntryById({ getEntryImport, collectionNames, }: {
|
|
31
34
|
getEntryImport: GetEntryImport;
|
|
35
|
+
collectionNames: Set<string>;
|
|
32
36
|
}): (collection: string, id: string) => Promise<{
|
|
33
37
|
id: any;
|
|
34
38
|
collection: any;
|
|
35
39
|
data: any;
|
|
36
|
-
}>;
|
|
40
|
+
} | undefined>;
|
|
37
41
|
type ContentEntryResult = {
|
|
38
42
|
id: string;
|
|
39
43
|
slug: string;
|
|
@@ -54,9 +58,10 @@ type EntryLookupObject = {
|
|
|
54
58
|
collection: string;
|
|
55
59
|
slug: string;
|
|
56
60
|
};
|
|
57
|
-
export declare function createGetEntry({ getEntryImport, getRenderEntryImport, }: {
|
|
61
|
+
export declare function createGetEntry({ getEntryImport, getRenderEntryImport, collectionNames, }: {
|
|
58
62
|
getEntryImport: GetEntryImport;
|
|
59
63
|
getRenderEntryImport: GetEntryImport;
|
|
64
|
+
collectionNames: Set<string>;
|
|
60
65
|
}): (collectionOrLookupObject: string | EntryLookupObject, _lookupId?: string) => Promise<ContentEntryResult | DataEntryResult | undefined>;
|
|
61
66
|
export declare function createGetEntries(getEntry: ReturnType<typeof createGetEntry>): (entries: {
|
|
62
67
|
collection: string;
|
|
@@ -70,15 +75,48 @@ type RenderResult = {
|
|
|
70
75
|
headings: MarkdownHeading[];
|
|
71
76
|
remarkPluginFrontmatter: Record<string, any>;
|
|
72
77
|
};
|
|
78
|
+
export declare function renderEntry(entry: DataEntry | {
|
|
79
|
+
render: () => Promise<{
|
|
80
|
+
Content: AstroComponentFactory;
|
|
81
|
+
}>;
|
|
82
|
+
}): Promise<{
|
|
83
|
+
Content: AstroComponentFactory;
|
|
84
|
+
} | {
|
|
85
|
+
Content: any;
|
|
86
|
+
headings: any;
|
|
87
|
+
remarkPluginFrontmatter: any;
|
|
88
|
+
}>;
|
|
73
89
|
export declare function createReference({ lookupMap }: {
|
|
74
90
|
lookupMap: ContentLookupMap;
|
|
75
|
-
}): (collection: string) =>
|
|
91
|
+
}): (collection: string) => z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodObject<{
|
|
92
|
+
id: z.ZodString;
|
|
93
|
+
collection: z.ZodString;
|
|
94
|
+
}, "strip", z.ZodTypeAny, {
|
|
95
|
+
id: string;
|
|
96
|
+
collection: string;
|
|
97
|
+
}, {
|
|
98
|
+
id: string;
|
|
99
|
+
collection: string;
|
|
100
|
+
}>, z.ZodObject<{
|
|
101
|
+
slug: z.ZodString;
|
|
102
|
+
collection: z.ZodString;
|
|
103
|
+
}, "strip", z.ZodTypeAny, {
|
|
104
|
+
collection: string;
|
|
76
105
|
slug: string;
|
|
106
|
+
}, {
|
|
107
|
+
collection: string;
|
|
108
|
+
slug: string;
|
|
109
|
+
}>]>, {
|
|
110
|
+
id: string;
|
|
77
111
|
collection: string;
|
|
78
|
-
id?: undefined;
|
|
79
112
|
} | {
|
|
113
|
+
slug: string;
|
|
114
|
+
collection: string;
|
|
115
|
+
} | undefined, string | {
|
|
80
116
|
id: string;
|
|
81
117
|
collection: string;
|
|
82
|
-
|
|
83
|
-
|
|
118
|
+
} | {
|
|
119
|
+
collection: string;
|
|
120
|
+
slug: string;
|
|
121
|
+
}>;
|
|
84
122
|
export {};
|