--- name: Error Boundary menu: Data Display route: components/errorBoundary --- import { Playground, Props } from 'docz'; import { ErrorBoundary } from '@ohif/ui'; # Error Boundary This component can be used to display a message or handle unhandled errors. ## Import ```javascript import { ErrorBoundary } from '@ohif/ui'; ``` ## Basic usage
{() => { throw new Error('Error!'); return

; }}
## Custom error fallback {() => { const CustomFallback = ({ error, componentStack, resetErrorBoundary }) => { return (

This is a custom fallback!

); }; return (
{() => { throw new Error('Error!'); return

; }}
); }}
## Properties