UNPKG

@devino.solutions/upup

Version:
16 lines (15 loc) 461 B
import { Component, ErrorInfo, PropsWithChildren, ReactNode } from 'react'; declare type Props = PropsWithChildren<{ fallback?: ReactNode; }>; export default class ErrorBoundary extends Component<Props, { hasError: boolean; }> { constructor(props: Props); static getDerivedStateFromError(): { hasError: boolean; }; componentDidCatch(error: Error, errorInfo: ErrorInfo): void; render(): ReactNode; } export {};