constructor([path], [stroke], [background], [opacity], [x], [y])

Class: Shape.

Description:

Shape constructor.

Parameters:

Name Type Default Description

[path]

string

Path consisting of points. It can be auto-generated by performing operations of one shape to another, such as add() or subtract().

[stroke]

Stroke

A border of the shape.

[background]

string

Color, gradient, image, and background options like in CSS.

[opacity]

number

1

Opacity of the shape as a decimal between 0 and 1.

[x]

number

0

Position of the shape from left edge.

[y]

number

0

Position of the shape from the top.