-
Notifications
You must be signed in to change notification settings - Fork 10
Closed
Description
Hi, great library!
Found an issue when serializing a field with more than one double quote.
For instance a value of John Dwayne "The Rock" Johnson is serialized as "Dwayne ""The Rock" Johnson".
When trying to parse that with CSV.parse it throws CSVError: Illegal state.
Code snippet:
const CSV = require('@vanillaes/csv'); const data = [ [ "header1", "header2", "header3" ], [ "aaa", "bbb", 'Dwayne "The Rock" Johnson' ], [ "zzz", "yyy", "xxx" ] ]; const stringified = CSV.stringify(data); const rows = CSV.parse(stringified);
Throws:
Error: CSVError: Illegal state [row:2, col:3]
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels