jinja2 set variable from javascript code example
Example: jinja2 set variable
{% if 'clear' in forcast_list[4] %}
{% set img = "sunny.png" %}
{% elif "cloudy" in forcast_list[4] %}
{% set img = "sun-cloudy-thunder.png" %}
{% endif %}
{% if 'clear' in forcast_list[4] %}
{% set img = "sunny.png" %}
{% elif "cloudy" in forcast_list[4] %}
{% set img = "sun-cloudy-thunder.png" %}
{% endif %}