If you don’t need fancy (streaming etc) and the JSON elements don’t contain line breaks, you can use the following function
parse = t => t.split("\n")
.filter(s => s !== "")
.map(s => JSON.parse(s))
If you don’t need fancy (streaming etc) and the JSON elements don’t contain line breaks, you can use the following function
parse = t => t.split("\n")
.filter(s => s !== "")
.map(s => JSON.parse(s))