-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[PAY 23/02] [Performance] Make the Search Sidebar transition relatively smooth on slower devices #33596
Comments
Triggered auto assignment to @bfitzexpensify ( |
Bug0 Triage Checklist (Main S/O)
|
@hurali97 Could you comment on this one? |
Pr is close to be merged |
@mountiny, @bfitzexpensify, @situchan Whoops! This issue is 2 days overdue. Let's get this updated quick! |
@mountiny, @bfitzexpensify, @situchan Uh oh! This issue is overdue by 2 days. Don't forget to update your issues! |
Hey @mountiny 👋 |
Is there something else should I comment ? or just the above is fine :D |
Haha all good i just cannot assign external people who did not comment on the issue ;) |
If you are the assigned CME please investigate whether the linked PR caused a regression and leave a comment with the results. If a regression has occurred and you are the assigned CM follow the instructions here. If this regression could have been avoided please consider also proposing a recommendation to the PR checklist so that we can avoid it in the future. |
If you are the assigned CME please investigate whether the linked PR caused a regression and leave a comment with the results. If a regression has occurred and you are the assigned CM follow the instructions here. If this regression could have been avoided please consider also proposing a recommendation to the PR checklist so that we can avoid it in the future. |
PR was reverted because there was couple of regressions with lists, we need to address them in a new PR |
If you are the assigned CME please investigate whether the linked PR caused a regression and leave a comment with the results. If a regression has occurred and you are the assigned CM follow the instructions here. If this regression could have been avoided please consider also proposing a recommendation to the PR checklist so that we can avoid it in the future. |
This is not ready for payment yet. 2nd PR is in review |
huh - updating the title |
Please remove HOLD for payment from issue title |
Not overdue, pr is at works |
PR is at works |
@mountiny, @bfitzexpensify, @hurali97, @adelekennedy, @situchan Whoops! This issue is 2 days overdue. Let's get this updated quick! |
PR is in review |
@mountiny, @bfitzexpensify, @hurali97, @adelekennedy, @situchan Whoops! This issue is 2 days overdue. Let's get this updated quick! |
still in review |
Cool, sounds good to me. Offer sent @situchan |
Payment due Friday |
Payment complete - @situchan can you please complete the BZ checklist? Will copy it into a new comment |
BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
|
This is performance improvement, not bug. BZ Checklist doesn't apply here. |
I think this can be closed |
@mountiny, @bfitzexpensify, @hurali97, @situchan Whoops! This issue is 2 days overdue. Let's get this updated quick! |
### Problem
coming from here
When user navigates back from Search Sidebar there’s a noticeable delay and lag in closing the Search Sidebar. It mainly arises from withNavigationFocus HOC as it re-renders the BaseOptionSelector tree including OptionsList . Adding a memo to OptionsList doesn’t help as it’s parent gets re-rendered due to the withNavigationFocus HOC.
Also, we notice that due to isFocused state value in ActionItemView the ReportActionsList re-renders which also adds the overhead to the rendering cycle as it recreates the instances of recordTimeToMeasureItemLayout and loadOlderChats which are passed as props to ReportActionsList .
Solution
We can remove the withNavigationFocus HOC and add navigation listeners(focus, blur) in BaseOptionSelector and memoize OptionsListto not re-render when state is set in it’s parent. We can avoid recreating instances of recordTimeToMeasureItemLayout and loadOlderChats by wrapping them in useCallbacks and memoizing ReportActionsList .
The text was updated successfully, but these errors were encountered: