Skip to content

Allow traditional for loops #173

@vrugtehagel

Description

@vrugtehagel

It'd be neat if we allowed the traditional initialization; condition; afterthought-style loop in Vento, allowing things like

The even items:
{{ for let index = 0; index < items.length; index += 2 }}
  Index {{ index }}, item {{ item[index] }}
{{ /for }}

I feel like this should be doable, given the only allowed loop now must contain of - what do you think? Worth implementing?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions