Multiple Modal components
It is currently impossible to create multiple Modal components.
Here is the warning that appears:
Warning: Attempt to present <RCTModalHostViewController: 0x7f89e4f8c2a0> on <UIViewController: 0x7f89e4903770> which is already presenting <RCTModalHostViewController: 0x7f89e4f84f10>
I don't know if it is something you did on purpose but I think it would be a huge plus to be able to render multiple modals.
This is currently not possible, I'm working on supporting this. For now you should be able to nest
Ok great, thanks @javache !
Is this done in 0.19. I am running into the same issue and trying to put a safari view controller on a RCTModalHostViewController. This is not possible so far :(
+1
Does anyone have a workaround for this?
+1
How does this nesting work?
+1
+1
+1 Any progress on this?
You should be able to present them as
<Modal>
<Text>A</Text>
<Modal>
<Text>B</Text>
</Modal>
</Modal>
@javache so in the scenario you mention here, you would simply setState for visible on both at the same time if you wanted the nested <Modal></Modal>?
Update: I tested this, and it works perfectly. Thanks!
how will this work if i wanted to present a SFVC on top of of a modal or vice versa ?
Any progress on this?
@facebook-github-bot label Icebox
Hi there! This issue is being closed because it has been inactive for a while.
But don't worry, it will live on with ProductPains! Check out its new home: https://productpains.com/post/react-native/multiple-modal-components
ProductPains helps the community prioritize the most important issues thanks to its voting feature. It is easy to use - just login with GitHub.
Also, if this issue is a bug, please consider sending a PR with a fix. We're a small team and rely on the community for bug fixes of issues that don't affect fb apps.
@facebook-github-bot close
@charpeni tells me to close this issue. If you think it should still be opened let us know why.