/* eslint-disable no-console */ import { ErrorBoundary as Boundary } from 'react-error-boundary'; import { Button } from 'react-basics'; import useMessages from 'hooks/useMessages'; import styles from './ErrorBoundry.module.css'; const logError = (error, info) => { console.error(error, info.componentStack); }; export function ErrorBoundary({ children }) { const { formatMessage, messages } = useMessages(); const fallbackRender = ({ error, resetErrorBoundary }) => { console.log({ error }); return (

{formatMessage(messages.error)}

{error.message}

{error.stack}
); }; return ( {children} ); } export default ErrorBoundary;