4 ms·
bring back 2-way binding. There are use cases, where it greatly improves productivity. Leave the choice about it to the developer.
by yayr 8y ago
bring back 2-way binding. There are use cases, where it greatly improves productivity. Leave the choice about it to the developer.
- simplify 8y agoI wonder if this could be solved with a general jsx decorators feature? For example: <input @bind("username") name="username" /> ...where bind is a normal function in scope that receives the element and/or its props?
- yayr 8y agothere are various ways to put this into a syntax. one way would be to have a dedicated attribute that behaves this way for relevant components. This would then be similar to the vue.js approach https://vuejs.org/v2/guide/forms.html https://vuejs.org/v2/guide/forms.html <input model={myJsObject.text} /> or <input bindValue={myJsObject.text} /> At least for standard HTML components this should work, as they would only have one editable property.