createBooleanOperation
[DEPRECATED]. Use figma.union
, figma.subtract
, figma.intersect
, figma.exclude
instead.
Signature
createBooleanOperation(): BooleanOperationNode
Remarks
Using this function is not recommended because empty boolean operation nodes can have surprising, unpredictable behavior. It will eventually be remove. Use one of the functions listed above instead.
Creates a new, empty boolean operation node. The particular kind of operation is set via .booleanOperation
. By default, the value is "UNION"
.
This snippet, for example, creates a boolean operation node that is a union of a rectangle and an ellipse.
Create a boolean operation node
const node = figma.createBooleanOperation()
node.appendChild(figma.createRectangle())
node.appendChild(figma.createEllipse())