json-2-csv icon indicating copy to clipboard operation
json-2-csv copied to clipboard

Option to put ALL values in quotes when going from JSON to CSV?

Open ict-opr opened this issue 6 months ago • 1 comments

Hi, I use your extension at work as its a really helpful tool to unscrew the messed up CSV files our site exports.

I've been fiddling with the extension settings a bit but I can't find an option to have it put ALL values between quotes regardless of type. Personally I like having my CSV's like this, every column in "quotes" and ; semicolons for the separators. Example: "name_one";"name_two";"name_three";"name_four";"empty_field"; "Lorem";"Ipsum";"Hello";"World";"";

It makes it easier for me to read. What this tool seem to do when converting from JSON back to CSV is removing all quotes that it doesn't technically need and only adds them back where it needs to.

Is there already a setting for this and am I just being blind?

And if not could you perhaps add this "Encase/Wrap all values in quotes" feature?

ict-opr avatar Sep 03 '25 09:09 ict-opr

Hi @ict-opr, thanks for reporting this and great question. As of right now, it only wraps values that absolutely need to be wrapped, but it should be possible to add an option to wrap all values with the appropriate delimiter, if desired. I don't have much free time to be able to implement this right now, but would be open to a pull request if you or someone else is open to implementing this.

mrodrig avatar Oct 28 '25 01:10 mrodrig