Skip to content
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

Queries around library usage #31

Closed
Anand2489 opened this issue Nov 9, 2021 · 1 comment
Closed

Queries around library usage #31

Anand2489 opened this issue Nov 9, 2021 · 1 comment

Comments

@Anand2489
Copy link

Can we use this library in production level code or there are some limitations which should be highlighted ?

I have following queries around it though :-

  1. New parent would be able to completely control InPortal component via props & refs
  2. InPortal component would get new props in current render cycle of the parent without any delay
  3. Any case/scenario where teleporting components via react-reverse-portal won't work :)
  4. Event propagation happens w.r.t to the new parent in OutPortal or the detached node where InPortal component is mounted

@pimterry ^^

@pimterry
Copy link
Member

pimterry commented Nov 9, 2021

Yes, you can use this in production. I'm not aware of any general issues. To know if it will work in your environment I'd suggest trying it out in a small prototype, I can't really advise in much more detail without fully understanding your setup.

With regards to your questions, yes, the new parent can control props and those should apply immediately.

Event propagation goes through the InPortal, not the OutPortal (see #13). That's how react's portals work everywhere - I'm open to exploring changes there if you have suggestions though.

@pimterry pimterry closed this as completed Nov 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants