Usage
Template Variables
Learn how to use template variables and preview props in your document templates
Overview
Template variables allow you to create dynamic documents by passing data to your templates. This guide shows you how to define and use template variables in your JSX templates.
Using Template Variables
Create a template component that accepts props for dynamic content:
Preview Props
Define preview data for development and testing using PreviewProps
:
Complex Objects
You can use nested objects and arrays for more complex templates:
Dynamic Values
You can use JavaScript expressions and functions in your preview props: