Video yükleniyor...

Video Yüklenemedi

Ana Sayfaya Dön

❌ Avoid using useState for more complex state management ✅ Instead use useReducer ↓

124,069 görüntüleme • 2 yıl önce •via X (Twitter)

11 Yorum

George Moller profil fotoğrafı
George Moller2 yıl önce

I've been working professionally with React for more than 8 years and I compiled all my knowledge into 100+ infographics just like this one. Check them out ↓

George Moller profil fotoğrafı
George Moller2 yıl önce

I've been working professionally with React for more than 8 years and I compiled all my knowledge into 100+ infographics just like this one. Check them out ↓

statuscast profil fotoğrafı
statuscast2 yıl önce

Help your IT team cut through 'Are you down?' clutter with StatusCast’s Audience Specific Status Pages. Tailor your status page to each user's role and needs for effective incident communication.

Rahi Jamil profil fotoğrafı
Rahi Jamil2 yıl önce

Totally agree! useReducer simplifies state transitions and makes code more maintainable. 🎯 #ReactJS #useState #useReducer

Bart ⚡ profil fotoğrafı
Bart ⚡2 yıl önce

Honestly, I always think that when your state is too complex for useState then you did something wrong.

Chris Staudinger profil fotoğrafı
Chris Staudinger2 yıl önce

I'm loving this new visual style George! 🤩 And on point React tips as always! 😀

George Moller profil fotoğrafı
George Moller2 yıl önce

Always happy that you like the content Chris! Big fan of your content too 💪

Mithlesh profil fotoğrafı
Mithlesh2 yıl önce

That was life saver. Thanks 😊

George Moller profil fotoğrafı
George Moller2 yıl önce

Glad you found value in this tweet Mithlesh!

Pavel Romanov profil fotoğrafı
Pavel Romanov2 yıl önce

It is exactly what I noticed today on a code review😄 Besides the mentioned benefits, we have cleaner components in general since all state-related logic moved out of the component

George Moller profil fotoğrafı
George Moller2 yıl önce

Yes, useReducer has a better api than useState. Having said that, I still find use cases for useState.

Benzer Videolar