-
Notifications
You must be signed in to change notification settings - Fork 56
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
feat!: return promise from field mount fn #1162
Conversation
how does it work for supernova objects? |
They have an onMount thing that I'm not 100% sure why it actually works. I've looked at making it so that the return "Viz" resolves when the chart is rendered (in my createApi PR) but that was quite the hassle. I think the Viz resolves when the onMount callback into Cell resolves, which is done when the loadType function finishes. Then there is a renderCount thing in Supernova that also does stuff... pending more reading... |
Yeah, I made the assumption that the promise returned from the But maybe the render function doesn't work like I assumed... |
It is hard to track but I think it don't wait for the render. |
So I dug: In client we call the innermost render function directly, which resolves when all the hook-ing is done. Christians approach here is fine I think, good if it resolves when rendering is done. |
Return a promise from the field mount function to indicate when all data fetching is done.
This can be used to determine when the listbox finishes rendering.
Awaits data pages to arrive and maxFrequencyCount when needed.