Values · Value
Sort lines
Sort the lines of a text A to Z, by length, or by the numbers in them, and drop repeats.
text.sort_lines
In a flow
“Works out sort lines whenever a step wired to it needs the answer.”
c\nb\na → a\nb\nc
What it does
Sort the lines of a text A to Z, by length, or by the numbers in them, and drop repeats. It's a value node: no white pins, it works out its answer when a step wired to it needs it. It gives 3 values later steps can use. Find it under Values in the palette.
When to use it
Use it when a step needs a value worked out first: sort the lines of a text A to Z, by length, or by the numbers in them, and drop repeats.
When not to
For a value that never changes, type it into the setting instead of wiring a node.
Typical wiring
Sockets: settings you can wire
- Text Text
-
One item a line.
What goes there: Type it in the side panel, or wire in text. e.g. Hello there
If it's empty: Optional. Left empty and unwired, it uses pear apple fig apple.
Connects fromA member's variablesAccept applicationAdd a Notion pageAdd a Trello cardAdd an emojiAdd to number in objectAdd up timesAdd working daysand 844 more
- Backwards Yes / no
-
Put the last first.
What goes there: Type it in the side panel, or wire in true or false. e.g. true
If it's empty: Optional. Left alone, it's off.
Connects fromAdd a labelAdd to a leaderboardAge from birthdayAI check a messageAnagram checkAndAnswer a deadlineAnti-nuke guardand 270 more
- Drop repeats Yes / no
-
Keep each line once.
What goes there: Type it in the side panel, or wire in true or false. e.g. true
If it's empty: Optional. Left alone, it's off.
Connects fromAdd a labelAdd to a leaderboardAge from birthdayAI check a messageAnagram checkAndAnswer a deadlineAnti-nuke guardand 270 more
Values it gives
- Text Text
-
The sorted lines. e.g. apple fig pear
If it's empty: Empty when the step didn't make one (it stopped early or was skipped); steps reading it get nothing.
Connects toAccept applicationAdd a forum tagAdd a labelAdd a Notion pageAdd a row to a Google SheetAdd a staff noteAdd a stickerAdd a Trello cardand 577 more
- Lines List
-
The same as a list. e.g. ["apple"]
If it's empty: Empty when the step didn't make one (it stopped early or was skipped); steps reading it get nothing.
Connects toAdd onboarding questionAdd to listAdd up timesAutoMod: add or remove allowed wordsAutoMod: add or remove wordsAutoMod: block wordsBar chartBest by a fieldand 88 more
- How many Number
-
Lines kept. e.g. 3
If it's empty: Empty when the step didn't make one (it stopped early or was skipped); steps reading it get nothing.
Connects toAccount ageActive membersAddAdd answer to formAdd soundboard soundAdd timeAdd to a counterAdd to a leaderboardand 718 more