${}
Last updated
Last updated
These special characters empower you to delve into the complete context and seamlessly integrate it with JavaScript syntax, allowing you to dynamically replace the values enclosed within ${} characters. This mechanism enables dynamic content substitution, facilitating the manipulation and customization of values within the context of your workflow or application.
The application of this special character is similar to Javascript's template literals.
Template literals are literals delimited with backtick (
`
) characters, allowing for multi-line strings, string interpolation with embedded expressions, and special constructs called tagged templates.Template literals are sometimes informally called template strings, because they are used most commonly for string interpolation (to create strings by doing substitution of placeholders). However, a tagged template literal may not result in a string; it can be used with a custom tag function to perform whatever operations you want on the different parts of the template literal.
This special characteres is inteded for retrieving primitive values of the context.
In case you want to return the entire object, you can use the js/ syntax to achieve it.
This special characters are allowed to be used while setting up a node's configuration. For example:
In this example, the utilization of special characters within ${}
is evident in the context of accessing data from the ctx
(context) through the body.property
. This syntax allows for dynamic retrieval of values from the context, enhancing the flexibility and adaptability of the code.
This special syntax allows you to access to context during the execution of the node, but remember that it will make a replacement of the string literal, it is not going to map an object.