Use macros with array of objects (key, values)

Hi Zola people / Vincent,

I try to add some features with my site,
how can i use macros with Zola, like this:
{% macro breadcrumb(items) %}

    {% for url, title in items %}
  • {{ title }}
  • {% endfor %}
{% endmacro breadcrumb %}

and function:
{% block breadcrumb %}
{{ breadcrumb_macros::breadcrumb(
items=[{“url1”:“urlName1”, {“url2”:“urlName2”} }
) }}
{% endblock breadcrumb %}

I read Tera docs, but can’t figure it out, examples only with array of strings

It’s not supported in Tera currently

ok keats, thank you
I thought I do something wrong,
because on Tera main page there is example

{% for user in users -%}
  <li><a href="{{ user.url }}">{{ user.username }}</a></li>
{%- endfor %}

The example works, it’s the literal dict support ([{“url1”:“urlName1”, {“url2”:“urlName2”} }]) that is not implemented in Tera.

Tera or Zola?
in Tera playground everything work
i guess i should read the sources,
my goal is to create a tab bar based on a macro component and switch active tab for current page by component config
thank you

This example doesn’t use dict literals though?