import { defineCollection } from "astro:content"; import { glob } from "astro/loaders"; import { z } from "astro/zod"; const pages = defineCollection({ loader: glob({ base: "./src/content", pattern: [ "*/*.{md,mdx}", "*.{md,mdx}", ]}), schema: z.object({ title: z.string(), subtitle: z.string(), date: z.iso.date(), settings: z.looseObject({}).optional(), }) }); export const collections = { pages };