feat: Upgrade template based on projects made with it
Some checks failed
Build, check & Test / run (push) Failing after 42s
Some checks failed
Build, check & Test / run (push) Failing after 42s
Signed-off-by: Florian Bouillon <f.bouillon@aptatio.com>
This commit is contained in:
@ -1,15 +0,0 @@
|
||||
// 1. Import utilities from `astro:content`
|
||||
// import { defineCollection, z } from 'astro:content'
|
||||
|
||||
// 2. Define your collection(s)
|
||||
// const docsCollection = defineCollection({
|
||||
// type: 'content',
|
||||
// schema: z.object({
|
||||
// title: z.string()
|
||||
// })
|
||||
// })
|
||||
// 3. Export a single `collections` object to register your collection(s)
|
||||
// This key should match your collection directory name in "src/content"
|
||||
// export const collections = {
|
||||
// 'docs': docsCollection,
|
||||
// };
|
29
src/content/config.ts.tmp
Normal file
29
src/content/config.ts.tmp
Normal file
@ -0,0 +1,29 @@
|
||||
// 1. Import utilities from `astro:content`
|
||||
import { defineCollection, z } from 'astro:content'
|
||||
|
||||
// 2. Define your collection(s)
|
||||
const projectsCollection = defineCollection({
|
||||
type: 'content',
|
||||
schema: ({ image }) => z.object({
|
||||
title: z.string(),
|
||||
description: z.string().optional(),
|
||||
image: image().optional(),
|
||||
link: z.object({
|
||||
href: z.string(),
|
||||
rel: z.string().optional(),
|
||||
text: z.string().optional(),
|
||||
target: z.string().optional()
|
||||
}).optional(),
|
||||
disabled: z.string().optional(),
|
||||
created: z.date().optional(),
|
||||
updated: z.date().optional(),
|
||||
techs: z.string().array().optional()
|
||||
})
|
||||
})
|
||||
|
||||
|
||||
// 3. Export a single `collections` object to register your collection(s)
|
||||
// This key should match your collection directory name in "src/content"
|
||||
export const collections = {
|
||||
projects: projectsCollection
|
||||
}
|
Reference in New Issue
Block a user