Creating a log boundaries utility for wrapping react errors
This commit is contained in:
parent
916b38c589
commit
6bcc351fa2
|
@ -0,0 +1,12 @@
|
||||||
|
// @flow
|
||||||
|
export type Info = {
|
||||||
|
componentStack: string,
|
||||||
|
}
|
||||||
|
|
||||||
|
export const logComponentStack = (error: Error, info: Info) => {
|
||||||
|
// eslint-disable-next-line
|
||||||
|
console.log(error)
|
||||||
|
// eslint-disable-next-line
|
||||||
|
console.log(info.componentStack)
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in New Issue