markdoc.config.mjs (870B)
1 import { defineMarkdocConfig, component } from '@astrojs/markdoc/config'; 2 3 export default defineMarkdocConfig({ 4 tags: { 5 card_grid: { 6 render: component('@astrojs/starlight/components', 'CardGrid'), 7 attributes: { 8 // Markdoc requires type defs for each attribute. 9 // These should mirror the `Props` type of the component 10 // you are rendering. 11 // See Markdoc's documentation on defining attributes 12 // https://markdoc.dev/docs/attributes#defining-attributes 13 stagger: { type: Boolean }, 14 }, 15 }, 16 card: { 17 render: component('@astrojs/starlight/components', 'Card'), 18 attributes: { 19 title: { type: String }, 20 icon: { type: String }, 21 }, 22 }, 23 }, 24 });