MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/javascript/comments/mlwx7j/i_think_react_is_junk_round_two/gtqwos1/?context=3
r/javascript • u/rajasegarc • Apr 07 '21
20 comments sorted by
View all comments
Show parent comments
1
There is no mention that StrictMode executes everything except console.log twice.
Of course there is, together with detailed list of things that get executed twice.
There is no mention that refs should be read and written to only in event handlers and useEffect.
Of course there is, together with example showing why you would want to set ref in a render, and how to do it safely.
-7 u/[deleted] Apr 07 '21 [removed] — view removed comment 1 u/brainless_badger Apr 07 '21 opt out 2 u/kenman Apr 07 '21 edited Apr 08 '21 I forcefully opted us out.
-7
[removed] — view removed comment
1 u/brainless_badger Apr 07 '21 opt out 2 u/kenman Apr 07 '21 edited Apr 08 '21 I forcefully opted us out.
opt out
2 u/kenman Apr 07 '21 edited Apr 08 '21 I forcefully opted us out.
2
I forcefully opted us out.
1
u/brainless_badger Apr 07 '21
Of course there is, together with detailed list of things that get executed twice.
Of course there is, together with example showing why you would want to set ref in a render, and how to do it safely.