-
Notifications
You must be signed in to change notification settings - Fork 47.2k
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
Add a <ReactDOM.Portal /> element #11586
Comments
I would like to make a pr for it, it may take sone time to invesitigate and do some test l. |
well first of all... do we want it? it definitely looks cleaner but are there any cons? |
I do agree it reads a bit better. I think we mostly intended However there is a bigger issue of portals not being feature-complete. Ideally we want to add support for server rendering in some way (e.g. by letting the container be a string). We also wanted to support cross-renderer portals. We thought that at that point we would move the API into So I think overall I agree this needs to be done, but I'd prefer to do it at the same time as other changes, and just make it |
I'm going to close this in favor of #10711. |
How are these related @gaearon? |
From my reply above:
#10711 is the issue tracking "isomorphic" portals (at which point we might as well make them more ergonomic to use). |
Do you want to request a feature or report a bug?
I’d like to request a feature.
What is the current behavior?
To create a portal, you currently have to use a function:
What is the expected behavior?
The text was updated successfully, but these errors were encountered: