wf4/content.config.ts
webfussel 9b66a79a8c add: category, date sorting
Add category layouts and date sorting
2025-07-11 13:32:59 +02:00

30 lines
No EOL
631 B
TypeScript

import { defineContentConfig, defineCollection, z } from '@nuxt/content'
export default defineContentConfig({
collections: {
blog: defineCollection({
type: 'page',
source: 'blog/*.md',
schema: z.object({
date: z.string(),
excerpt: z.object({
type: z.string(),
children: z.any(),
}),
}),
}),
skills: defineCollection({
type: 'page',
source: 'snippets/skills/*.md',
}),
faq: defineCollection({
type: 'page',
source: 'snippets/faq/*.md',
schema: z.object({
rawbody: z.string(),
}),
}),
},
})