Skip to content
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

Add support for .ui.xml templating #43

Open
TadeasKriz opened this issue Mar 1, 2018 · 0 comments
Open

Add support for .ui.xml templating #43

TadeasKriz opened this issue Mar 1, 2018 · 0 comments

Comments

@TadeasKriz
Copy link
Member

Two options:

  1. Have a different file extension: .ui.template.xml that would get precompiled to .ui.xml by the Generator.

  2. Have support for this directly in .ui.xml and running the transformation in-memory before parsing the XML.

It could be something like (pseudo Stencil code):

<Component>
    <array field="rows">
    {% for i in 1...5 %}
    <Label 
        layout:id="row_$i" 
        layout:fillHorizontally="super"
        {% if :first %}layout:below="id:row_$1"{% else %}layout:top="super"{% endif %}
        {% if :last %}layout:bottom="super"{% endif %}
    />
    {% endfor %}
    </array>
</Component>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant