{% macro slicedString(str, style='') %} {% for slice in str|split('(?=[\.\/\{\}])') %}{{slice}}{% endfor %} {% endmacro %}