blob: 2780035b16882b808ab294e59a9463465b20e648 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
import { defineCollection, z } from 'astro:content';
import { SITE } from '../consts';
const docs = defineCollection({
schema: z.object({
title: z.string().default(SITE.title),
description: z.string().default(SITE.description),
lang: z.literal('en-us').default(SITE.defaultLanguage),
dir: z.union([z.literal('ltr'), z.literal('rtl')]).default('ltr'),
image: z
.object({
src: z.string(),
alt: z.string(),
})
.optional(),
ogLocale: z.string().optional(),
}),
});
export const collections = { docs };
|