Comment on page
Conditions and logic
Modify your flow's behavior using answers collected.
Conditional logic is useful for making flows dynamic, funneling users into specific tracks, or making a flow more personalized: rather than creating multiple flows for different scenarios, flow questions can be rendered dynamically based on the answers the responder has provided.
Conditions can be used to control many aspects of a flow:
If rendering an item depends on a single answer, it can be defined using our Simple Logic editor. To access, navigate to the Logic tab of the component, then Show conditionally -> Add condition.
The simple logic menu
Here you can select an answer variable, set the operator, and choose the value desired.
If the conditional rendering of your step depends on more than one condition being satisfied, the simple logic editor can accept several arguments using the +Add condition button in the simple logic menu.
The logic between several variables can be configured using either the AND or OR logical operators at one time.
A multi-clause simple logic editor joining several conditions with an AND statement
You can also nest the logic of conditions by grouping (+Add group) the logic.
This will allow you to set slightly more advanced conditions, such as ensuring one variable condition is satisfied while comparing the value between two other variables.
Variable a is defined, and the logical comparison of variables fruit and is_true needs to be resolved
If the logic you are trying to express involves a combination of multiple different answers, you can use advanced logic to define arbitrary boolean expressions over the answers.
For even more complicated conditional logic, define a
boolean(True/False) calculated variable, which allows you to use arbitrary Typescript to create conditional a T/F return, which can then be used in a simple logic check.
Toggling on Optional? for a Question allows users to progress past a question without answering it. The default behavior for Formsort flows is to let users progress only when all questions have been satisfied; optional can override this.