How to reimplement the "wrapper" from getCollectionNode
in the new CollectionBuilder
from a "@react-aria/collections"?
#8232
-
Hi there! 👋
But there’s another
Is there any way to achieve desired behaviour with a "wrapper" from |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
We have contemplated opening createBranchComponent in the same way as createLeafComponent. I think I explored in in a PR at one point. This one https://github.com/adobe/react-spectrum/pull/7289/files We'll likely have to solve something similar when we get to Coachmarks as well. I know an approach we've used in the past has been to render the overlays separately, and position them by finding the target in the dom. We'd also like to avoid that because it typically means needing to implement polling and retry logic, but it could work for now. |
Beta Was this translation helpful? Give feedback.
We have contemplated opening createBranchComponent in the same way as createLeafComponent. I think I explored in in a PR at one point. This one https://github.com/adobe/react-spectrum/pull/7289/files
We decided on a different way to implement it. Maybe this can help you as well so that you don't need collections inside every component of yours.
We'll likely have to solve something similar when we get to Coachmarks as well. I know an approach we've used in the past has been to render the overlays separately, and position them by finding the target in the dom. We'd also like to avoid that because it typically means needing to implement polling and retry logic, but it could work for now.