dominictarr / JSONStream

rawStream.pipe(JSONStream.parse()).pipe(streamOfObjects)
Other
1.92k stars 165 forks source link

Parsing JSON without object at root #46

Open apoco opened 9 years ago

apoco commented 9 years ago

I have an API endpoint that accepts JSON bodies that are not JSON objects. JSONStream doesn't emit a root event in the scenario of, say, a stream containing true.

I am investigating a fix and can provide a PR, but would you be opposed to a JSON stream emitting any type of JSON value?