-
Notifications
You must be signed in to change notification settings - Fork 29.5k
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
Explore notebook list view impl #170881
Comments
Here is what I learnt so far while exploring our own list view
With these in mind, here are some optimizations we can make to the notebook cell list view:
Future more, we could explore
|
After shipping #171681 for around two days, even though we didn't see layout issues coming, I ran into NPEs frequently when opening notebooks. Digging this a bit I realize that nesting
This made a bit concerned with |
@joaomoreno 🖕 let's discuss this on Monday. I think to make it correct, we probably do need the pendingUpdateQueue concept, as long as we have element height change while rendering the element. |
Here are my thoughts after our discussion:
It's still not 100% clear to me why this behavior was implemented in the first place. The list never expected its user to "lie" when it probes for the actual height. From what I can tell, the current implementation is based on the fact that probing for the actual height of a code editor cell is way too expensive, if that cell is eventually not going to fit in the viewport. Final thoughts:
|
Step 2 used to be noticeably slow as at the time we render some outputs in the renderer process, meaning we are checking the Above is the major reason why we skip "renderElement(height: undefined)", you are correct that we are against this pattern: Back to today's notebook list view rendering, we are very close to have Step 1 only but only facing two challenges:
I like this idea a lot. It's worth an experiment. Short summary:
|
Closing this as I don't think a custom listview implementation is needed |
We currently a dozen of layout related issues #169038 and fixing them requires having more patches on the our notebook cell list. Let's see if we can swap out the default list view impl with our own and simplify the layout logic and at the end, reduce our maintenance cost in overall.
The text was updated successfully, but these errors were encountered: