I have a textfield, which I want to have a 'dynamic' placeholder text (definied and managed in the view), but I also want it to have an action defined for it. I tried the two following lines:
{{ input id="test" placeholder=view.text action expand target="view"}}
<input type="text" id="test" placeholder="{{view.text}}" {{action expand target="view"}} />
Both are not working. So my question is, is there a way to achieve what I want or would it be easier to have a focus handler in the view, which just filters for the id (and then calls the expand function)?
If you want to stick to input helpers, you can do something like this:
{{input placeholder=view.text action="expand" targetObject=view}}
Notice that targetObject should not be a string.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With