Nik96i / revite

React Vite Starter
1 stars 0 forks source link

Handling app's unexpected errors (Error Boundary) #27

Open Nik96i opened 5 months ago

Nik96i commented 5 months ago

Wrap the entire app into some error handler component to show an error page whenever an unexpected error happens! In the production mode, it should appear and prevent the user from seeing the actual error on the page.

Nik96i commented 5 months ago

Maybe we can use this: https://www.npmjs.com/package/react-error-boundary