-
-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathcontent.config.ts
34 lines (33 loc) · 887 Bytes
/
content.config.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
import { defineCollection, z } from '@nuxt/content'
export const collections = {
snippets: defineCollection({
type: 'data',
source: 'snippets/*.yml',
schema: z.object({
name: z.string().nonempty(),
code: z.object({}),
description: z.string().nonempty(),
keyword: z.string().nonempty(),
tags: z.array(z.string().nonempty()).optional(),
})
}),
aiCommands: defineCollection({
type: 'data',
source: 'ai-commands/*.yml',
schema: z.object({
name: z.string().nonempty(),
description: z.string().nonempty(),
prompt: z.object({}),
tags: z.array(z.string().nonempty()).optional(),
})
}),
content: defineCollection({
type: 'data',
source: '**/*.yml',
schema: z.object({
title: z.string().nonempty(),
description: z.string().nonempty(),
about: z.object({}),
})
})
}