Break
Stop the nearest loop from inside its body.
Type
loop.break Block Loops
Folder
basic/loopsChannels
Any
Pipe
Unset
Scope
Callback
Break stops the nearest active loop. Place it inside a loop callback scope (after Lambda, often behind a condition). It has no outgoing handle — that branch of the body ends.
It belongs in callback scope, not on the main path. Outside an active loop body the run fails.
Values already returned in earlier iterations stay on the loop’s result list. The current iteration is not collected as a normal return.
Configure
There are no settings — the block only emits a stop signal.
Handles
| Handle | Role |
|---|---|
| In (target) | Incoming connection (from a block inside the loop body) |
There is no Out. Connect Break at the end of the branch that should exit the loop.
Pipe schema
This block does not pass a value along the main graph. The parent loop still puts its collected list on the pipe when it finishes.
Use case
- Inside For Of or For In, stop after the first matching item instead of walking the rest.
- Inside While or Do While, exit from a nested branch without returning
falsefrom every path. - Pair with a condition: true path → Break, false path → finish the body. Use Continue when you only want to skip this iteration.