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

Decide on error boundaries. #771

Closed
tech4him1 opened this issue Oct 31, 2017 · 3 comments
Closed

Decide on error boundaries. #771

tech4him1 opened this issue Oct 31, 2017 · 3 comments

Comments

@tech4him1
Copy link
Contributor

Now that we are on React 16, we should probably decide where to create "error boundaries" (https://reactjs.org/blog/2017/07/26/error-handling-in-react-16.html). Right now, thrown errors will now dismount the entire app if not caught. Should they be per-widget? per-page? per-component?

@erquhart
Copy link
Contributor

erquhart commented Nov 7, 2017

Agreed, thanks for raising this.

A prescriptive approach is probably best. Error boundaries can actually be dangerous otherwise - allowing parts of the app to run while other parts are inactive can lead to cases we simply don't expect and aren't set up for.

The first applied error boundary, and a generic, reusable boundary component, are in #779.

@tech4him1
Copy link
Contributor Author

What about creating an error boundary around the entire app, so we don't just get a blank white screen on crash?

@erquhart
Copy link
Contributor

With the generic component and the app now wrapped in it, I think we can close this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants