Templating Principles
This is the Directual syntax for dealing with object fields 📜
Last updated
This is the Directual syntax for dealing with object fields 📜
Last updated
To work with data in scenarios and filters, you can use Templating. Directual's Templating system is based on the library, with some useful add-ons to the basic technology.
To use the value of a field, we type its system name in double curly braces: {{field_system_name}}
. To fetch the property value of a linked object, type the field-link followed by a dot and the system name of the linked object {{field_type_of_link.linked_object_field}}
.
There are two types of input fields for templating. The first is a smart select:
This field also has a smart field inputs option. When it's ON, you can choose fields directly in the text, and typing "{{" will activate the smart inline select. Turn it off if needed.
Note, that you can nest fields of linked objects like {{book_author.name}}
, where 'book_author'
is a field type of link. However, this doesn't work for arrayLinks! To work with arrayLink fields, use the .
The second is a text area field. This field has an option to evaluate (coding mode).
Use to check the result of templating.