Editor / DOM Helper / jqSelector
Function: jqSelector()
ts
function jqSelector(selector): JQuery<HTMLElement>;Resolves a given selector string into a jQuery object based on predefined rules.
Parameters
| Parameter | Type | Description |
|---|---|---|
|
| A string representing the selector. It can include special shortcuts such as |
Returns
JQuery<HTMLElement>
A jQuery object corresponding to the resolved selector.
Examples
ts
// Resolving a simple selector
jqSelector('#my-element'); // Returns a jQuery object for #my-elementts
// Using `$` shortcut for node input
jqSelector('$node-name');
// Resolves to: #node-input-node-name
// Returns a jQuery object for the resolved selectorts
// Using `$$` shortcut for node config input
jqSelector('$$config-name');
// Resolves to: #node-config-input-config-name
// Returns a jQuery object for the resolved selector