Skip to main content

Home > @jsplumbtoolkit/browser-ui > Component

Component class

Base class for Endpoint and Connection.

Signature:

export declare abstract class Component extends EventGenerator 

Extends: EventGenerator

Constructors

ConstructorModifiersDescription
(constructor)(instance, idPrefix, params)Constructs a new instance of the Component class

Properties

PropertyModifiersTypeDescription
instanceJsPlumbInstance
typeIdstring

Methods

MethodModifiersDescription
addClass(clazz, cascade)Adds a css class to the component
getClass()Returns a space-separated list of the current classes assigned to this component.
getData()Gets any backing data stored against the given component.
mergeData(d)Merges the given backing data into any current backing data.
removeClass(clazz, cascade)Removes a css class from the component
setData(d)Sets backing data stored against the given component, overwriting any current value.