Loading...
Asked by Alex Nelson on Jun 26, 2024
Alex wants to know if there's a way to make some content within an email module visible only when editing the email in the HubSpot editor, and hidden when the email is actually sent.
Answered by James Kupczak
James provides a HubL snippet using `{% unless contact.email and contact.email != 'CONTACT.EMAIL' %}`. This condition checks if the `contact.email` personalization token is absent or has its default placeholder value, which is typically true in the editor context but false in a live send. Content placed inside this block will only render in the editor.