astrocms 0.4.2 → 0.4.3
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.
|
@@ -3,12 +3,18 @@
|
|
|
3
3
|
* Only exports the APIs the user's config is expected to import from this module.
|
|
4
4
|
* Loader factories (glob, file) live in 'astro/loaders' and are stubbed there.
|
|
5
5
|
*/
|
|
6
|
-
|
|
6
|
+
import { z } from 'zod'
|
|
7
|
+
|
|
8
|
+
export { z }
|
|
7
9
|
|
|
8
10
|
export function defineCollection(config: any) {
|
|
9
11
|
return config
|
|
10
12
|
}
|
|
11
13
|
|
|
14
|
+
/**
|
|
15
|
+
* In frontmatter, a reference is stored as the id of the referenced entry,
|
|
16
|
+
* so it is edited as a plain string.
|
|
17
|
+
*/
|
|
12
18
|
export function reference(_collection: string) {
|
|
13
|
-
return
|
|
19
|
+
return z.string()
|
|
14
20
|
}
|