Skip to main content

Home > @jsplumbtoolkit/browser-ui > SurfaceRenderOptions > modelEvents

SurfaceRenderOptions.modelEvents property

Optional map of event handlers. Each entry consists of the event name, a CSS selector to target, and a callback function. Supplying this is equivalent to calling bindModelEvent(..) on a Surface.

Signature:

modelEvents?: Array<{
event: string;
selector: string;
callback: ModelEventCallback<Edge | Node | Group | Port | Vertex>;
}>;