template-archive
template-archive copied to clipboard
Should CiceroMark support iterators blocks?
Iterators Blocks ❌
Eventhough you could use an Ergo expression for this feature, we could also support:
{{#foreach products}}
- Product: {{name}}
{{/foreach}}
{{#foreach(",") products}}Product: {{name}}{{/foreach}}
This would be sometimes easier to write/read and would enable parsing for arrays of complex objects.
Issue inherited from #392
@jeromesimeon - I think this would be very useful. This would be a much more elegant and concise way to handle interior blocks.
In addition, as Ergo Expressions do not currently support markdown format then this would be a way to properly format text rendered by interior expressions.
For example:
{{#foreach products}}
- _Product:_ **{{name}}**
{{/foreach}}
Currently, there is no way (that I'm aware of) to format text rendered within interior blocks.