Open
Description
Hello, everyone!
My App is React with TS latest version.
I wanted to pass level, errorMessage , extra to ErrorBoundary like this:
const level = (error: Error, info: ErrorInfo): LEVEL => error instanceof TypeError ? LEVEL_ERROR : LEVEL_WARN;
but i get an error: Type '(error: any, info: any) => "warn" | "error"' is not assignable to type 'LEVEL | (() => LEVEL) | undefined'.
I changed type in index.d.ts in @rollbar package with pass (error, info) to this values in ErrorBoundaryProps, but it doesn't help for me.
I did something wrong or what?