import React, { FunctionComponent, ReactElement } from "react"; import { ErrorBoundary as NativeErrorBoundary } from "react-error-boundary"; export interface ComponentProps { children?: ReactElement; } const Fallback: FunctionComponent = () => { return (
An unexpected error has occurred. Please reload the page to continue
); }; const ErrorBoundary: FunctionComponent = ( props: ComponentProps, ) => { return ( {props.children} ); }; export default ErrorBoundary;