Skip to main content

$let

The $let operator declares a variable in the current scope.

Input

  • An array containing exactly two values: the variable name (string) and the value to assign to the variable

Output

  • The assigned value

Examples

Basic Variable Assignment

Result: 42

Assign Field Value to Variable

Result: The value of the name field, which is also stored in the user_name variable

Use in a Block

Result: The calculated total value including tax