Common issue with synchronizing state in React

Common issue with synchronizing state in React

React Tips with Brooks Lybrand

4 года назад

3,831 Просмотров

Ссылки и html тэги не поддерживаются


Комментарии:

@neelabhdutta6691
@neelabhdutta6691 - 11.10.2021 20:05

You may use e.target.value directly, anything that is not reactive, i.e input that changes only by user activity, should not be a state at all.. still if you need it... rather use a ref in that case

Ответить
@BoNez37
@BoNez37 - 16.07.2021 11:17

dude thank you so much for this tutorial! I couldn't get my head around how this was supposed to work but the way you explained it made me get it instantly!

Ответить
@kosm8745
@kosm8745 - 09.03.2021 13:26

Thanks , nice explanation!!

Ответить
@cesartabares6203
@cesartabares6203 - 30.12.2020 19:54

Thanks a lot, I was struggling with this for couple of hours, the second way and more clean clode, didn't work for me, I think is because so many things are involved, but using the UseEffect just solved the problem

Ответить