UtilsAPI.isTransformableLayer
Returns true if the given value is a TransformableLayer.
UtilsAPI.isTransformableLayer() method
Returns true if the given value is a TransformableLayer.
Signature:
isTransformableLayer(node: Layer | Shape): node is TransformableLayer;Parameters
Parameter | Type | Description |
|---|---|---|
node | The value to check |
Returns:
node is TransformableLayer
true if node is a TransformableLayer, otherwise false.
Example
for (const node of creator.selection.nodes) {
if (creator.utils.isTransformableLayer(node)) {
// node is narrowed to TransformableLayer
console.log(node.position.staticValue);
}
}Last updated: October 8, 2026 at 10:45 AMEdit this page