Something went wrong. Try again.
Fork of backnotprop/plannotator with reduced surface area
Something went wrong. Try again.
12345678910111213141516171819202122232425262728293031import { defineCollection, z } from 'astro:content';import { glob } from 'astro/loaders';
const docs = defineCollection({ loader: glob({ pattern: '**/*.md', base: './src/content/docs' }), schema: z.object({ title: z.string(), description: z.string(), sidebar: z.object({ label: z.string().optional(), order: z.number(), }), section: z.string().optional(), }),});
const blog = defineCollection({ loader: glob({ pattern: '**/*.md', base: './src/content/blog' }), schema: z.object({ title: z.string(), description: z.string(), date: z.coerce.date(), author: z.string().default('backnotprop'), tags: z.array(z.string()).default([]), draft: z.boolean().default(false), ogImage: z.string().optional(), }),});
export const collections = { docs, blog };