Since my Google-Fu is failing me, I simply want to know:
How can I use JSONStream.stringify()
to create a string containing JSON. I can find hundreds of examples that create a file, but none that simply create a string.
Edit: my usecase is that I have a large list of objects (and sometimes a small list of very large objects) which I need to turn into a JSON string. JSON.stringify cops out with a RangeError: Invalid string length
, which is why I want to use JSONStream
.