Fixed content collections
This commit is contained in:
parent
c94fb25aba
commit
65d4339b9f
12 changed files with 67 additions and 111 deletions
src/content
28
src/content/config.ts
Normal file
28
src/content/config.ts
Normal file
|
@ -0,0 +1,28 @@
|
|||
import { z, defineCollection } from 'astro:content'
|
||||
|
||||
const taInfo = defineCollection({
|
||||
type: 'data',
|
||||
schema: z.object({
|
||||
info: z.object({
|
||||
title: z.string(),
|
||||
questReleaseDate: z.string(),
|
||||
shortdescription: z.string(),
|
||||
description: z.string(),
|
||||
fightNumber: z.number().default(1),
|
||||
}),
|
||||
data: z.array(
|
||||
z.object({
|
||||
title: z.string(),
|
||||
link: z.string().url(),
|
||||
date: z.string(),
|
||||
servant: z.string(),
|
||||
turns: z.string(),
|
||||
runner: z.string(),
|
||||
})
|
||||
),
|
||||
}),
|
||||
})
|
||||
|
||||
export const collections = {
|
||||
taInfoData: taInfo,
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue