Skip to main content

Expected outcome:

As a Klaviyo user editing a plain text template, I can use the merge tags documented on Klaviyo’s official documentation here in a plain text template to iterate through a “list” (denoted as such a data type in the field by the “y]” characters) following this format: 

`{% for item in person.field_name %}{{ item.name }} {% endfor %}` 

And the item values in that list will populate in the plain text email

 

Actual Outcome

  1. Attempting to preview this in-app immediately dumps the user into the “we sent you an email” modal (although no email is ever received)
  2. Attempting to save this template triggers a top “Error” toast notification and the inspect element shows a 400 error request with the http response:  ```{
        "errors":
            "Unclosed tag on line 21: 'for'. Looking for one of: empty, endfor."
        ],
        "warnings": ]
    }```
  3. Strangely, there seems to be some script that ‘deletes’ both the prepended and appended `{% for item in person.segment_interests %}`and `{% endfor %}` tags upon clicking either the preview or save buttons

 

Is there a workaround and is the klaviyo team aware of this issue?

 

 

Interestingly, I’m noticing more generally that any merge tags for a `{{ person }}` level attribute are not displaying at all in the Preview Section, even for tags that don’t trigger the bug discussed above, even something like `{{ person.id }}` does not display, and this is a system-assigned unique id for the record 🤔


Reply