Documents / @faasjs/react / ErrorBoundary
Class: ErrorBoundary
Extends
Component
<ErrorBoundaryProps
,object
>
Constructors
new ErrorBoundary()
new ErrorBoundary(
props
):ErrorBoundary
Parameters
• props: ErrorBoundaryProps
Returns
Overrides
`Component< ErrorBoundaryProps, { error?: Error info?: { componentStack?: string } }
.constructor`
Methods
componentDidCatch()
componentDidCatch(
error
,info
):void
Catches exceptions generated in descendant components. Unhandled exceptions will cause the entire component tree to unmount.
Parameters
• error: Error
• info: any
Returns
void
Overrides
Component.componentDidCatch
render()
render():
string
|number
|boolean
|Iterable
<ReactNode
,any
,any
> |Element
Returns
string
| number
| boolean
| Iterable
<ReactNode
, any
, any
> | Element
Overrides
Component.render
Properties
whyDidYouRender
static
whyDidYouRender:boolean
=true