single-spa / single-spa-react

Single-spa lifecycles helper for React applications
https://single-spa.js.org/docs/ecosystem-react.html
MIT License
227 stars 63 forks source link

Do not log a warning when the `errorBoundaryClass` is provided #171

Closed nickbosland closed 1 year ago

nickbosland commented 1 year ago

When a parcel is mounted it checks if errorBoundary is set or it implements the componentDidCatch function, if those are not available it will log a warning to the console. This warning is always logged when you use the errorBoundaryClass property.

It is possible to work around this by setting suppressComponentDidCatchWarning but that feels a bit weird, so this PR fixes this issue by include an additional check if the errorBoundaryClass is set

joeldenning commented 1 year ago

Released in https://github.com/single-spa/single-spa-react/releases/tag/v5.1.0