Mohan Ram
1 min readJan 8, 2019

--

In your login component sample.

As you mentioned in later part of blog . Hooks will not merge your update while managing the state. Please correct as

<input id='username' onInput={() => setLoginDetails(prev => ({ ...prev, username: this.value }))} />

Nice article!

--

--