Skip to main content

Expressions

Learn how to write expressions for Yumdocs.

Tip

Yumdocs uses a custom implementation of JEXL by default, but can be configured to use any expression engine.

Object properties

Object properties are in the form "name": value where value can be a string (between quotes), a boolean (true or false), a number, an object (between curly braces) or an array (between square brackets).

An object is a collection of properties. An array is a collection of values.

A property is evaluated by its name. If the value of a property is an object (e.g person), a dot is used to access the properties of this object (e.g. person.firstName), which you can experiment in the following playground:

Loading...

Array items

An array item is most commonly accessed by its index in square brackets as in organization.members[0], but expressions can also include queries, which you can experiment in the following playground:

Loading...

Concatenation

Expressions support concatenation, which you can experiment in the following playground:

Loading...

Calculations

Expressions support calculations, which you can experiment in the following playground:

Loading...

Conditions

Expressions support conditions, which you can experiment in the following playground:

Loading...