I'm using a Wordpress theme that was developed using Twig template system. I don't know anything about Twig an don't have the time to learn it.
So my question is, in Wordpress we can use get_terms() to get all the terms from a taxonomy but we can filter the terms we want to receive using an array of arguments that is the second parameter to the function.
That being said, I have a line in a twig file that goes like this:
{% for distrito in wp.get_terms('Distritos') %}
distrito is my variable and Distritos is my taxonomy name. This works, it calls all of the terms, but I want to use the array arguments so that I can get only the root elements since my taxonomy has hierarchy.
I understand that I must have somewhere the place where wp.get_terms is defined but I can't find it.