Merge pull request #34654 from ChristieRobson/recompose/lifecycle

[recompose]: add componentDidCatch to lifecycle
This commit is contained in:
Armando Aguirre
2019-04-16 13:43:38 -07:00
committed by GitHub

View File

@@ -257,6 +257,7 @@ declare module 'recompose' {
componentWillUpdate?: (this: ReactLifeCycleFunctionsThisArguments<TProps, TState, TInstance>, nextProps: TProps, nextState: TState) => void;
componentDidUpdate?: (this: ReactLifeCycleFunctionsThisArguments<TProps, TState, TInstance>, prevProps: TProps, prevState: TState) => void;
componentWillUnmount?: (this: ReactLifeCycleFunctionsThisArguments<TProps, TState, TInstance>) => void;
componentDidCatch?:(this: ReactLifeCycleFunctionsThisArguments<TProps, TState, TInstance>, error: Error, info: React.ErrorInfo) => void;
}
export function lifecycle<TProps, TState, TInstance = {}>(