I am creating some <app-route> elements in a <dom-repeat> as follows:
<template is="dom-repeat" items="{{myItems}}">
<app-route route="[[_route]]"
pattern="/view-{{index}}/:data"
data="{{_routeData}}"
active="{{_routeActive}}">
</app-route>
</template>
I'd like to use {{index}} within the data and active attribute values to
create a dynamic binding property name such as {{_route{{index}}Data}} i.e
evaluating {{index}} when creating the binding name. This would mean that
they are unique for each route.
Is it possible to do this in Polymer? If not are there any alternative
approaches?
Thanks,
Mark
(Originally asked on Stack Overflow
http://stackoverflow.com/questions/40009627/can-you-dynamically-create-a-binding-property-name-in-polymer
with no answer).
Follow Polymer on Google+: plus.google.com/107187849809354688692
---
You received this message because you are subscribed to the Google Groups
"Polymer" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/polymer-dev/e883d922-ebf2-4404-9bed-629982e38279%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.