Is it possible to do something like this in jinja2:
my_list = ['foo1', 'bar1', 'foo2', 'bar2']
[i for i in my_list if 'foo' in i]
I looked at the map and join, something like:
{% my_list|map('???')|join(' ') %}
But I cannot find a filter that would like me to execute any wildcard queries. The two closest ones look like "equal" and "equal", but they do not work quietly.
source
share