1 | ;
|
2 | Object.defineProperty(exports, "__esModule", { value: true });
|
3 | exports.transformSplit = void 0;
|
4 | const _binarySplit = require('binary-split');
|
5 | /**
|
6 | * Input: stream (objectMode=false) of arbitrary string|Buffer chunks, like when read from fs
|
7 | * Output: stream (objectMode=false) or string|Buffer chunks split by `separator` (@default to `\n`)
|
8 | *
|
9 | * Useful to, for example, reading NDJSON files from fs
|
10 | */
|
11 | function transformSplit(separator = '\n') {
|
12 | return _binarySplit(separator);
|
13 | }
|
14 | exports.transformSplit = transformSplit;
|