React Update Lifecycle: что происходит при обновлении компонента
В этой статье последовательно разобран полный цикл обновления React: от Virtual DOM до внутреннего устройства Fiber Reconciler. Разобраться в жизненном цикле React
We've added 26 new Shadcn Blocks and 8 new UI Components, including Waitlist, Coupon, Product Comparison, AI Ops, Forms, Calendar App, Card, Rating, and more.
[HELP] Not sure how to properly fix new "react-hooks/set-state-in-effect" ESlint rule enforced with React 19.2.0
Hey all I have finally updated my React Native App which also comes with an update of React to 19.2.0.
That version of React adds/activates a new ESLint rule named react-hooks/set-state-in-effect. Which does make sense to enforce I guess and I did found a couple of places where I was able save one or two unnecessary re-renders but here I really am not sure what the best fix is. Here is a simplified but reproducible example:
exportdefaultfunctionSyncIndicator({loading}){const[visible,setVisible]=useState(false);constopacity=useAnimatedValue(0);useEffect(()=>{if(loading){setVisible(true);// react-hooks/set-state-in-effect violation constanimation=Animated.timing(opacity,{toValue:1,duration:200});animation.start();}else{constanimation=Animated.timing(opacity,{toValue:0,duration:200});animation.start(()=>{setVisible(false);// this is fine as its async });}},[loading,opacity]);if(visible){return(<Animated.Viewstyle={{opacity}}><ActivityIndicatorcolor={'#194159'}/></Animated.View> );}else{returnnull;}}
Theoretically this would just render it three times I believe which is not perfect, but wouldn’t at-least end up being an infinite loop.
Honestly from UX standpoint it would be even better to get rid of visible and enable pointerEvents only if loading is true to make it pass down events if half opaque. It would even make the code cleaner, but I also do want to know now how people on here would fix it.
Did anybody else found themselves with ESLint screaming at you after updating React? Is there a clean fix to this?
Can we talk about how it's absolutely wild that some really basic usability issues with JSX have since not been addressed since I first learned of #React back in the early Stone Age? Even CSS manages to map "gray" to "grey", but class to className? Apparently impossible! Having two expressions instead of one? Even more impossible!
Заметки фром реакт документейшен | React: грабли, о которые я спотыкалась. Часть 1
React я использую совсем недавно и вообще я бэкенд разработчик, но жизнь завела меня во фронтенд. Получилось так, что времени на обучение и курсы у меня не было, пришлось обучаться прямо в процессе. Мой принцип был "работает и ладно", но принципы нормального фронтенда явно отличались. Шишек я набила знатных с точки зрения чистоты и логики кода. Это статья для таких же новичков, как я. Представляю вам сборник граблей, о которые я спотыкалась сама, и решений к этим граблям, которые родились после нескольких часов дебага и внимательного изучения документации (спустя пол года во фронтенде пора бы, да?)
AAA Движок для GTA San Andreas в браузере и переписывание ThreeJS
Данная статья - это продолжение повествования о том, как я делаю AAA-движок для запуска старых игр, а именно GTA San Andreas и её модов, в браузере. В ней речь пойдет о том, как я уперся в производительность Three.js и перевел движок на свой фреймверк под WebGPU.
New React project: BingeMeter tells you how long it'll take to binge a show, using real per-episode runtime data from TMDB. Hit a nasty race condition fixed with AbortController.
Summer is not over and we are still out bringing some great performances.
Our first Last Call of 2026 is finally coming up and we will be back to Finland for the second time of the year!!!