Closed udanpe closed 6 years ago
The documentation in Github is for the next release, 4.0, which will introduce a lot of changes and goodness.
For the current release, you should follow the instructions in npm.
The main change is that instead of const csv = json2csv(myCars, { fields });
you should do const csv = json2csv({ data: myCars, fields });
@udanpe please confirm if that was your issue.
just used the library & const csv = json2csv({ data: myCars, fields });
helped. thanks mate!
I'll keep this open until the 4.0 release in case anyone else gets into the same confusion.
@juanjoDiaz
const csv = json2csv({ data: myCars, fields });
Its works. Thanks.
v4.0.0 released
copy\paste example and Error.. node 4,6,8 macos