We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent df1ac62 commit fd546a5Copy full SHA for fd546a5
index.d.ts
@@ -0,0 +1,19 @@
1
+import React from 'react';
2
+
3
+export interface FallbackProps {
4
+ error?: Error;
5
+ componentStack?: string;
6
+}
7
8
+export interface ErrorBoundaryProps {
9
+ onError?: (error: Error, componentStack: string) => void;
10
+ FallbackComponent?: React.ComponentType<FallbackProps>;
11
12
13
+export function withErrorBoundary<P>(
14
+ ComponentToDecorate: React.ComponentType<P>,
15
+ CustomFallbackComponent?: React.ComponentType<FallbackProps>,
16
+ onErrorHandler?: (error: Error, componentStack: string) => void,
17
+): React.ComponentType<P>;
18
19
+export default class ErrorBoundary extends React.Component<ErrorBoundaryProps>{}
0 commit comments