Skip to content

Commit

Permalink
Keystatic test
Browse files Browse the repository at this point in the history
  • Loading branch information
gxjansen committed Jun 8, 2024
1 parent b3ece5b commit 8ca0cc8
Showing 1 changed file with 20 additions and 22 deletions.
42 changes: 20 additions & 22 deletions keystatic.config.ts
Original file line number Diff line number Diff line change
@@ -1,28 +1,26 @@
import { config, fields, collection } from '@keystatic/core';

export default config({
storage: {
kind: 'local',
},
storage: {
kind: 'local',
},

collections: {
posts: collection({
label: 'Posts',
slugField: 'title',
path: 'src/content/blog/*',
format: { contentField: 'content' },
schema: {
title: fields.string({ name: { label: 'Title' } }),
content: fields.string({
label: 'Content',
}),
author: fields.string({
label: 'Author',
}),
date: fields.date({
label: 'Date',
}),
},
collections: {
posts: collection({
label: 'Posts',
slugField: 'title',
path: 'src/content/blog/*',
format: { contentField: 'content' },
schema: {
title: fields.slug({ name: { label: 'Title' } }),
content: fields.document({
label: 'Content',
formatting: true,
dividers: true,
links: true,
images: true,
}),
},
},
}),
},
});

0 comments on commit 8ca0cc8

Please sign in to comment.