Basics - Fluid Topics - Latest

Jinja Connector Reference Guide

Category
Reference Guides
Audience
public
Version
Latest

When creating a Jinja template, use {{ and }} to render a variable.

Example:

Source:

{'name': 'John Doe'}

Template:

<p>Name: {{ data.name }}</p>

Result:

<p>Name: John Doe</p>

Use {% and %} to write Python code.

Example

{% if data.name == 'John Doe' %}you again ?{% endif %}
{% for item in data.myList %}<p>{{ item }}</p>{% endfor %}