Re:Rich Harris joins Vercel to work on Svelte full time
by awestroke on Friday November 12, 2021 @03:14AM
(#29197273)
It's never two-way in react. You're always in charge of updating the state in the event handler, which means you know where the update came from
[ Parent
| on HN ]
Re:Rich Harris joins Vercel to work on Svelte full time
by keb_ on Friday November 12, 2021 @09:53AM
(#29199797)
Not to argue semantics, but that pattern is still called two-way databinding in my neck of the woods. In this deprecated page from the official docs, two-way databinding is defined as:
> Two-way binding — implicitly enforcing that some value in the DOM is always consistent with some React state — is concise and supports a wide variety of applications.