-
Notifications
You must be signed in to change notification settings - Fork 13.5k
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
bug: useIonModal dismiss() does not unmount component #23517
Comments
Thanks for the issue. Could you reproduce this issue in an Ionic starter app and provide a link to the repo? I see you also reported #23516, so feel free to just re-use the reproduction from there. |
Thanks for the issue! This issue has been labeled as Please reproduce this issue in an Ionic starter application and provide a way for us to access it (GitHub repo, StackBlitz, etc). Without a reliable code reproduction, it is unlikely we will be able to resolve the issue, leading to it being closed. If you have already provided a code snippet and are seeing this message, it is likely that the code snippet was not enough for our team to reproduce the issue. For a guide on how to create a good reproduction, see our Contributing Guide. |
Hi Liam Absolutely, here ya go! |
I can reproduce this behavior. Likely related to #23516 given that the overlay is not rendered within the app context. |
Thanks for the update @liamdebeasi ! Yeah, i figured the two had some crossover. |
Hi @liamdebeasi - sorry to ping this issue- but wanted to see if it makes sense to close this issue as something that won't be addressed for v5. Thanks again! |
Thanks for the ping! I can confirm that this issue will only be fixed in Ionic 6. Ionic 5 is only receiving critical security fixes now. I am going to close this as this issue is resolved in Ionic 6. |
Thanks so much @liamdebeasi ! That officially nudges us to upgrade to v6! ;) |
Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out. |
Bug Report
Ionic version:
[ ] 4.x
[ x] 5.x
[ ] 6.x
Current behavior:
The new
useIonModal
hook does not unmount the component that is being used as the modal whendismiss()
is called.Expected behavior:
The
present
function mounts the component and thedismiss
function unmounts and removes the component from the React tree.Steps to reproduce:
Follow the docs for
useIonModal
Related code:
Below is a video of the react component tree as i
present
anddismiss
the modal using the return tuple fromuseIonModal()
ionic-modal-hook-test.mov
Ionic info:
The text was updated successfully, but these errors were encountered: