scaffold
This commit is contained in:
17
src/content.config.ts
Normal file
17
src/content.config.ts
Normal file
@@ -0,0 +1,17 @@
|
||||
import { defineCollection } from 'astro:content';
|
||||
import { glob } from 'astro/loaders';
|
||||
import { z } from 'astro/zod';
|
||||
|
||||
const services = defineCollection({
|
||||
loader: glob({ pattern: '**/*.md', base: './src/content/services' }),
|
||||
schema: z.object({
|
||||
title: z.string(),
|
||||
description: z.string(),
|
||||
icon: z.string().optional(),
|
||||
image: z.string().optional(),
|
||||
order: z.number().default(0),
|
||||
featured: z.boolean().default(false),
|
||||
}),
|
||||
});
|
||||
|
||||
export const collections = { services };
|
||||
Reference in New Issue
Block a user