I need to use loop-counter in a pythonic for-loop in an html template file. How do I do it? Following is a piece of code that would provide a better idea of what I'm trying to say.
{% for idx, keyword in enumerate(keywords) %}
...do something with idx
{% endfor %}
Here, 'keywords' is a list that I get through the Django dictionary. "Could not parse the remainder: '(keywords)' from 'enumerate(keywords)'" is what I get for the first line. Any suggestions would be appreciated. Thanks!