Skip to content

The Basics/Utility Classes/StringLineIterator

Reference Documentation

Find reference documentation for StringLineIterator here, or navigate to it via the 'Reference' tab.

StringLineIterator iterates over the lines of a provided input string.

1
2
3
4
5
6
7
let iter: StringLineIterator = new StringLineIterator(`Hello
there,
world!`);

for (let line of iter) console.log(line);

// Prints 'Hello', 'there,', 'world!'.