csvtomd-web
csvtomd-web copied to clipboard
Pipe characters are not escaped, breaking tables
Same issue as mzjp2/mdtable/issues/7, I will copy-paste the bug report below. Tested just now at https://csvtomd.com/
Input CSV (LibreOffice):
Header,HeaderC2,Header C3
Normal line,another,And the last
if (OK && GREAT),it works,as expected
If (ouch || bad),oopsie,doopsie
Output Markdown (mdtable input.csv > output.md)
| Header | HeaderC2 | Header C3 |
| ---------------- | -------- | ------------ |
| Normal line | another | And the last |
| if (OK && GREAT) | it works | as expected |
| If (ouch || bad) | oopsie | doopsie |
You can see the || characters are not escaped to \|\| thus producing a broken result (pasted below). Simply escaping the characters as shown works on Github.
| Header | HeaderC2 | Header C3 |
|---|---|---|
| Normal line | another | And the last |
| if (OK && GREAT) | it works | as expected |
| If (ouch | bad) |