Skip to content

Conditional Content

We provide a very user-friendly way of managing conditional content in the template. We like to think about conditional content as variants of the structures.

To enable section variants start by enabling it in Topol Options:

js
enableSectionVariants: true,

Add structure variant

Variants

Add condition for certain variant

Variants

Switch between variants and edit its content

Variants

Conditions play very nice together with Merge Tag Previews

Condition Syntax

We currently support conditional syntax compatible with Mailchimp and SparkPost.

We are eager to expand our compatibility with additional providers. If you have a specific provider in mind, please reach out to our support team with your request.

You can choose this syntax setting an emailServiceProvider in Topol Options.

ts
emailServiceProvider: 'mailchimp' | 'sparkpost',