How does node convert json objects into data in json line format?

[
    {name:"allen"},
    {name:"kobe"}
]

convert to

{name:"allen"}
{name:"kobe"}

the difference is that record objects are separated by \ n instead of commas

. For more information on

jsonline format, please see jsonlines

.
Dec.02,2021

[
    {name:'allen'},
    {name:'kobe'}
].map((d)=>JSON.stringify(d)).join('\n')

look for yourself.
just like the you want

Menu