comma icon indicating copy to clipboard operation
comma copied to clipboard

escaping characters

Open baldarn opened this issue 6 months ago • 0 comments

hi! nice gem!

I was trying this with a field that have " and ,. is there a way to be super sure that the csv output is safe?

EG

m = Model.first
m.field = 'asd",lol'
Model.all.to_comma(force_quotes: true)

# output this feels broken
\"asd\"\",lol\"\n\

baldarn avatar Aug 21 '24 10:08 baldarn