I use Ember 2.8. There exists Map data structure in Ember. It should be iterable. However there's no examples how to enumerate through it and render it.
Assuming that both keys and values in my map are JS objects that have some 'name' set, I tried in Emblem:
each myMap.keys as |key|
p = key.name
each myMap.values as |value|
p = value.name
/ each myMap as |key, value| //this one causes build error
/ p = key.name
/ p = value.name
None of these syntaxes seem to work and render something more than 'undefined' empty space.
Do any of you know how to render a Map in Ember?
Aucun commentaire:
Enregistrer un commentaire