Node class
📖 Description
The Node class represents a node in the form definition.
🗃️ Fields
🏷️ id
Retrieves the identifier of the node.
Type
string
🏷️ index
Retrieves the zero-based index of the node in the Nodes collection.
Type
string
🏷️ isFirst
Retrieves if the node is the first node in the Nodes collection.
Type
boolean
🏷️ isLast
Retrieves if the node is the last node in the Nodes collection.
Type
boolean
🏷️ isVisible
Retrieves if the node is visible.
Type
boolean
🏷️ props
Retrieves the properties of the node.
Type
🏷️ runner
Retrieves a reference to the Runner instance.
Type
🏷️ section
Retrieves the parent section.
Type
🏷️ slots
Retrieves the Slots collection.
Type
▶️ Methods
🔧 block
Retrieves the block instance for the supplied context.
Signature
block(context: Context): NodeBlock | HeadlessBlock | undefined
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
context | Context | No | Reference to the context. |
Return value
Returns the NodeBlock or HeadlessBlock instance or undefined if the block was not found.
🔧 isAwaiting
Retrieves if one or more of the slots are awaiting a value.
Signature
isAwaiting(context: Context): boolean
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
context | Context | No | Reference to the context. |
Return value
Returns true if a slot is awaiting a value.