Is there a way to pass an argument to a Polymer function from an element attribute inside its ?
Is there a way to pass an argument to a Polymer function from an attribute of an element inside its .
Instead of using an event use a computed binding. Computed bindings can accept literal strings.
Checkout the working example below. In this example a button can be hidden based on the parameter that is passed.
Note: You can get the id
or other attributes of an element that an event is run on through event.target
. If you are only looking for other attributes as parameters this might also be a valid solution.