String Manipulation
Split, join, replace, and format strings.
What it does
String Manipulation covers everyday text work: replace, join, split, trim, case-change, search and repeat. Pick an Operation and only the parameters that operation needs are shown.
The node has four outputs, a string, a number, a boolean and a list, and only the one matching the chosen operation carries a value. Wire from Result for text, Number for Length and Index Of, Boolean for Contains, List Result for Split.
When to use it
Swapping one substring for another → Replace
Several find/replace pairs applied in one pass, for rule-based text rewriting → Replace All with parallel Find List / Replace List inputs
Breaking a path or CSV-style string into pieces, or gluing a list of strings back together → Split / Join
A character count, a single character, or a slice of a string → Length, CharAt, Substring
Testing or locating a substring → Contains, Index Of
Upper or lower case, whitespace trimmed off the ends, or a string repeated → ToUpper / ToLower, Trim, Repeat
| Parameter | Type | Default |
|---|---|---|
string | OneOf([String]) | — |
operation | String | "Length" |
find | String | "" |
replace | String | "" |
find_list | OneOf([Collection]) | — |
replace_list | OneOf([Collection]) | — |
other | OneOf([String]) | — |
index | Number | 0 |
start | Number | 0 |
end | Number | -1 |
delimiter | String | "," |
list | OneOf([Collection]) | — |
search | String | "" |
count | Number | 2 |
Gotchas
Join reads the List input, not the string input at the top of the node. Wire the strings to glue together into List; Split's List Result goes straight there. With nothing wired to List, Join gives an empty string, since there is nothing to join.
In Substring, End at -1 means to the end of the string. Any other value is treated as an exclusive end index.
Repeat is capped at 100 copies internally, so a very large Count yields 100 repeats.
Only one output pin is filled per operation. Length and Index Of write to Number, Contains writes to Boolean, Split writes to List Result, and every other operation writes to Result. Wiring the wrong pin for the chosen operation gives an empty value, not an error.
Replace All expects Find List and Replace List to be the same length and in matching order. Each entry in Find List is swapped for the entry at the same position in Replace List, in a single left-to-right pass over the string. Mismatched list lengths leave extra find or replace entries unused.
Worked example
Add a String Manipulation node and feed it a string, e.g.
"/assets/textures/wood.png".Set Operation to Split and Delimiter to
/, then wire List Result onward to work with each path segment.Add a second String Manipulation node, set Operation to Replace, Find to
.png, Replace to.jpg, to swap the file extension on the original string.To glue the segments back up, add a third String Manipulation node, set Operation to Join and Delimiter to
/, and wire the first node's List Result into its List input.
See also
String Generator · List Operations · Value · Numbers, signals & audio