Expand your options for documentation using custom content blocks.
Developers can define custom documentation blocks inside the exporter. These custom blocks take an input (or custom property), and are rendered in the documentation as is determined by the exporter. This allows endless opportunities for customization of your design system documentation.
You can define the following custom properties in a custom block:
- Component properties
- Token type
- Token properties
- Boolean (True/False)
After an exporter is installed containing custom blocks, these custom blocks will show in the list when inserting a new block.
- Open the blocks list (click + or type / )
- Select the custom block from the list to add it
- Enter the block specific value(s)
- Publish to see the result
Set the properties for the custom block:
- In your documentation editor, click the Settings icon
- Select the Blocks section
- Make changes to desired properties, and click Update
- Publish the documentation to see the new property values applied
If you are using custom blocks in your documentation and you switch to an exporter that doesn't have matching definitions for them, the block will be ignored. Otherwise, if there is a matching block definition, the the block will continue to be rendered by the new exporter.