Why is my app slow when rendering a lot of elements? #1909
-
Hi ! First of all, this library is so helpful, I working on a multi platform app (iOS, Android, Web) and my DX is very good, thanks a lot ! Unfortunately I have some performances issues on Web, but I'm not sure if it's because RNW or React in general. Here some context. We can see my app like a catalogue. The window is divide in two parts : Filters and Results So when I have approximately (with the addition of some elements like header, title, etc..) 1000 mounted views I have like a drop of fps (i'm not sure is that, I more a Mobile Dev than Web dev so i don't know how to monitor). I tried to optimize using React.memo when I can, limit at maximum the number of view, avoid anonymous function on ListView item, etc but it still so slooow Has anyone come across this problem before ? Thanks 😊 EDIT: FYI, when I say it's slow, it's visible when i type text on texfield, the text only appear after few milliseconds, or sometimes after few seconds ! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 5 replies
-
@gwenoleR Can you turn on Highlight updates in react dev tools and see what gets rerendered when you start typing? |
Beta Was this translation helpful? Give feedback.
-
@gwenoleR In addition to this, you can also debounce your function calls. It can help prevent excess function calls. |
Beta Was this translation helpful? Give feedback.
@gwenoleR Can you turn on Highlight updates in react dev tools and see what gets rerendered when you start typing?
I think this could give some insights.