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

What about the ErrorBoundary? #588

Open
nmdschultz opened this issue Oct 21, 2024 · 1 comment
Open

What about the ErrorBoundary? #588

nmdschultz opened this issue Oct 21, 2024 · 1 comment

Comments

@nmdschultz
Copy link

nmdschultz commented Oct 21, 2024

Hey there!

Due to the fact that the CascadingBlazoredModal is added to App.razor wrapping the router, it falls outside of the ErrorBoundary normally specified within MainLayout. This means that the error lands all the way out in my index.html in the <div id="blazor-error-ui">.

Ideally, if an exception is thrown from within my modals, I would like the following things to happen:

  • Close down the modal
  • Let my MainLayout handle the error (in this case it shows an error page to the user)

Does anyone have any good ideas of how to do this?
I have tried placing new ErrorBoundaries, adding @layouts and many other things, but it seems really tricky to get this right..

@nmdschultz
Copy link
Author

Any thoughts on this @chrissainty ? :)

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

1 participant