aboutsummaryrefslogtreecommitdiff
path: root/src/content/config.ts
blob: 4277edc8cf3b01bde46366196fec58a1e95c7a85 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
import { defineCollection, z } from "astro:content";

const blog = defineCollection({
	type: "content",
	schema: z.object({
		basedOn: z.optional(z.string()),
		dateModified: z.coerce.date(),
		datePublished: z.coerce.date(),
		description: z.string(),
		draft: z.optional(z.boolean()),
		lang: z.string(),
		title: z.string(),
	}),
});

export const collections = { blog };