asafdav / ng-csv

Simple directive that turns arrays and objects into downloadable CSV files
MIT License
573 stars 215 forks source link

force quote strings with spaces #171

Closed oflebbe closed 8 months ago

oflebbe commented 7 years ago

Hi,

libreoffice version 4 (yeah, it's ancient ...) does not import fields with embedded whitespaces correctly. For instance a field with contents "hi" there will be exported to ;""hi"" there; , but libreoffice does not honour the seperator tripping over later fields.

Even Excel 2010 does not import ;""hi"" there; correctly: It displays the double quote chars, not a single one.

With the supplied patch, the field will be exported as ;"""hi"" there"; which leads to correct exports in both libreoffice 4 and excel 2010.

oflebbe commented 7 years ago

Errr, The travis-ci error seems to be unrelated to my patch?