API REFERENCE

connect

link this chart's zoom / pan with other charts (elements or ids in this chart's root): every member's zoomChange reaches the others as zoomTo({ source: 'sync' }) on the axes (default 'x'). A newcomer is aligned to this chart. Calling again replaces the link.

Definition

typescript
connect(charts: ReadonlyArray<HTMLElement | string>, options?: ZoomConnectOptions): Promise<number>
ArgumentsTypeRequired
chartsReadonlyArray<HTMLElement | string>Required
optionsZoomConnectOptionsOptional

Return type: Promise<number>. Call the method after element registration and await its Promise result.