-
-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Suggestion: hidden list field with current item index #172
Comments
Not always: in Hugo, it's idiomatic to filter a collection right before looping into it (a |
Okay, let’s see how the hidden |
The fix shipped with v0.35.0 🚢 You can now use |
Thank you! |
The idea is: in a List widget with fields (e.g. not "simple string list"), one could add a hidden field that holds the index of the current item in that list, like:
It could be a
hidden
widget withdefault: '{{index}}'
, or acompute
widget withvalue: '{{index}}'
, or even something else...The text was updated successfully, but these errors were encountered: