I have an variable that I need to alter inside the template.
Let’s say the variable foo is 4, but I need the value to be foo + 1.
I’ll then use this in an if statement, like so:
{% if bar == foo+1 %}
<p>Condition has been met!</p>
{% endif %}
You can do
Or another is: