tinky / TaffyNode
Represents a node in the Taffy layout tree. This class wraps a Taffy node ID and manages its lifecycle.
id:
bigint
Unique identifier for the node within the Taffy tree.
optionalmeasureFunc?: (width) =>object
Callback function to measure the content of the node. Used for text nodes or other content with intrinsic size.
AvailableSpace
Available width for content.
object
Element dimensions.
height:
number
width:
number
tree:
TaffyTree
The Taffy tree instance this node belongs to.
free():
void
Removes the node and all its descendants from the Taffy tree. Necessary to prevent memory leaks as Taffy nodes aren't GC'd automatically.
void