---
id: "packages/active-charts/all-exports/chart-error-boundary"
title: "ChartErrorBoundary"
description: "ChartErrorBoundary, ChartErrorBoundaryProps: generated from the source of active-charts."
url: "/packages/active-charts/all-exports/chart-error-boundary"
locale: "en"
revision: "g0mvjxwj5c-88bdbe1c:chart-error-boundary"
---

# ChartErrorBoundary

Exported by `@workspace/active-charts`. Generated from the package source; part of [the index of every export](/packages/active-charts/all-exports).

## `ChartErrorBoundary`

| Prop | Type | Required | Description |
| --- | --- | --- | --- |
| `children` | `ReactNode` | yes |  |
| `fallback` | `((error: Error) => ReactNode) \| ReactNode` | no | Custom fallback to render instead of the default SVG message. |
| `height` | `number` | no | Height of the fallback SVG. Default: 200. |
| `onError` | `((error: Error, errorInfo: ErrorInfo) => void)` | no | Callback fired when an error is caught. |
| `resetKey` | `unknown` | no | When this value changes, the error state is cleared and children are re-rendered. Pass data identity (e.g. `data` reference or `data.length`) to auto-recover after data changes. |
| `t` | `ChartTranslateFn` | no | The host translator for the default fallback. When omitted, `<ChartDefaults>` supplies it; the default fallback without either throws a configuration error (no English copy, ADR-028). A custom `fallback` needs neither. |
| `width` | `number` | no | Width of the fallback SVG. When omitted, fills parent via 100%. |

## Types

**ChartErrorBoundaryProps**

```ts
interface ChartErrorBoundaryProps {
  children: ReactNode;
  width?: number;
  height?: number;
  fallback?: ReactNode | ((error: Error) => ReactNode);
  onError?: (error: Error, errorInfo: ErrorInfo) => void;
  resetKey?: unknown;
  t?: ChartTranslateFn;
}
```
