ErrorBoundary in React?

How do you recommend doing ErrorBoundary in React?

If I do it at the top of the hierarchy, I can’t do a redirect to / or anything because there is no view, thus no main view, thus nothing is routable. How do people handle this?

Can you give an example of how did you try to use it?

I’ve also found somewhat difficult to cope with F7 router in my admittedly very green experience.
Other than what you describe there are other situations where the router cannot figure out what to do next.
E.g. in componentDidUpdate I check whether the user is logged or not, and if they aren’t, I redirect them to /login.
Problem is, sometimes f7 complains that there is no view and the app hangs.
Only workaround I’ve found is to set
document.location.href = “/” (or something to that extent)
and the app restarts which is more or less what I wanted in the first place.