FUNCTION

text.split

pure function split(delimiter: text): list<text>

Splits this text around matches of the given delimiter.

Examples:

  • 'the cow jumped over the moon'.split(' ') returns ['the', 'cow', 'jumped', 'over', 'the', 'moon'].
  • 'giggling'.split('g') returns ['', 'i', '', 'lin', ''].
  • 'espresso'.split('a') returns ['espresso'].

Parameters

  • delimiter — the delimiter on which to split

Returns

a list<text> which is the result of splitting this text at each occurrence of delimiter

Since

0.6.0

© 2026 Chromia