Skip to main content

Home > @jsplumbtoolkit/browser-ui > Surface > rotate

Surface.rotate() method#

Rotate the given vertex by the given number of degrees. The DOM element representing the vertex is rotated and the view is updated.

Signature:

rotate(obj: string | Vertex, amountInDegrees: number): void;

Parameters#

ParameterTypeDescription
objstring | VertexEither a vertex ID, or a Node/Group
amountInDegreesnumberAmount - in degrees - to rotate.

Returns:

void