splits an stream on a character (e.g. \n) and emits the strings in between
Splits a string stream on a character (e.g. \n) and emits the strings in between.
npm install char-split
var split = require'char-split'streampipespliton'data'// line of texton'end'// end of streamon'error'// error in stream
splitcharacter = '\n'
For simplicity, char-split doesn't support multi-character split strings. This means splitting on \r\n won't work.
Open source software under the zlib license.