List Includes
Uncontrolled node
Overview
Check whether a list contains a value.
Check whether a value appears anywhere in a list. Use Index In List instead if you also need its position.
This node is evaluated when another node needs its output. It has no run or done event.
Inputs
| Input | Type | Description |
|---|---|---|
| list | List | The list to search. |
| pattern | Data | The value to find. The field accepts text; connect a Number, Boolean or other data value when you need a different type. |
Outputs
| Output | Type | Description |
|---|---|---|
| includes | Boolean | true when the value exists in the list. Returns false for no match, an empty list or a non-list input. |
Matching values
This is an exact-value check, not a partial-text search. Text is case-sensitive and types matter: 3 and "3" are different. Separately constructed objects or lists are not matched by their contents. To search a field in a list of records, use Map List to extract that field first.
Examples
| List | Pattern | Includes |
|---|---|---|
["red", "blue"] | "blue" | true |
["red", "blue"] | "Blue" | false |
[1, 2, 3] | 3 | true |
[1, 2, 3] | "3" | false |
Connect includes to If → test and trigger the If node through its run event when you want to branch.