Skip to main content

Expressions

The expression engine allows you to add dynamic logic to templates. Use expressions for text interpolation, conditional rendering, and data transformation.

Syntax

Expressions use double curly braces: {{expression}}

Simple Variables

Property Access

Access nested properties with dot notation:

Arithmetic

Comparisons

Logical Operators

Ternary Operator

Built-in Functions

String Functions

Number Functions

Formatting Functions

Array Functions

Type Checks

Utilities

Conditional Rendering

If/Else in Text

Conditional Objects

In template objects, use the _if property:
The object is only rendered if the condition evaluates to true.

Complex Conditions

Text Interpolation

Combine static text with expressions:
Multiple expressions in one string:

Testing Expressions

Test expressions before using them in templates:

Validate Syntax

Response:

Test with Data

Response:

List Available Functions

Examples

Personalized Greeting

Price Display

Date Formatting

Conditional Badge

Array Display