Document field - How to use Custom Components and Images #485
-
I think the documentation is still lacking on this but I wanted to use Keystatic for a blog. And ideally, the blog should have support for images, custom components & also some custom renderers for headings. I tried going through the Keystone.js documentation to maybe piece things together but I was unable to wrap my head around it. I was just wondering if there are some resources or content I can be pointed towards. Or otherwise any guidance on how I can figure this out. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
Hey! I have just added some documentation on the https://keystatic.com/docs/fields/document#component-blocks To enable images in your blog post's You can then use the We'll try to provide "real world" examples of how to use this really soon! |
Beta Was this translation helpful? Give feedback.
Hey!
I have just added some documentation on the
document
field's Component Blocks on Friday — probably 1 day after you posted this (and I only read this now on our Australian Monday morning) 😅https://keystatic.com/docs/fields/document#component-blocks
To enable images in your blog post's
document
field, you can add theimages: true
as mentioned here.You can then use the
DocumentRenderer
from@keystatic/core/renderer
to display a custom component when this component block is matched.We'll try to provide "real world" examples of how to use this really soon!