manavkush
TTCTheo's Typesafe Cult
•Created by manavkush on 8/24/2023 in #questions
Preventing Rerender of Parent component in React
Also I read about React.Memo while searching for a solution. If I Memo on the parent component, then the parent wouldn't rerender unless the props passed to it changes right? So we can memoize that then only the child would rerender on state updates.
8 replies
TTCTheo's Typesafe Cult
•Created by manavkush on 8/24/2023 in #questions
Preventing Rerender of Parent component in React
Ohhh.... I just thought that this rerendering would cause the app to slow. Also if I wanted another child component like to show the chat info on top(like other user's name etc) then it'd also get rerendered due to the parent being rerendered.
I'll try out the solutions you mentioned. Thanks !!!
8 replies