This commit is contained in:
2025-04-22 14:53:09 -03:00
parent 93186a7f9b
commit 61c4c454bd
75 changed files with 36 additions and 117 deletions

View File

@@ -2,17 +2,22 @@ import { defineCollection, z, reference } from 'astro:content'
import { glob } from 'astro/loaders'
const trainers = defineCollection({
loader: glob({ pattern: '**/*.md', base: './src/data/trainers' }),
loader: glob({ pattern: '**/*.md', base: './src/content/trainers' }),
schema: ({ image }) =>
z.object({
name: z.string(),
image: image(),
bio: z.string(),
networks: z.array(
z.object({
alt: z.string(),
url: z.string(),
}),
),
}),
})
const courses = defineCollection({
loader: glob({ pattern: '**/*.md', base: './src/data/courses' }),
loader: glob({ pattern: '**/*.md', base: './src/content/courses' }),
schema: ({ image }) =>
z.object({
id: z.string(),