MacDownApp / MacDownApp/macdown

Support escaping of table characters inside a table

Open
#623 4 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Rich Text Format
Stars
9.8k
Forks
1.2k
PR merge metrics
No merged PRs in 30d

Description

A normal pipe table produces the desired table in MacDown.

```
test | a | table
--- | --- | ---
one | two | three
```

A pipe table with an escaped pipe symbol in the header is not recognized as a table.

```
test | P(a\|b) | table
--- | --- | ---
one | two | three
```

Please take a look at the [Babelmark output](http://johnmacfarlane.net/babelmark2/?normalize=1&text=test+%7C+a+%7C+table%0A---+%7C+---+%7C+---+%0Aone+%7C+two+%7C+three%0A%0Atest+%7C+p%28a%5C%7Cb%29+%7C+table%0A---+%7C+---+%7C+---+%0Aone+%7C+two+%7C+three) for this example. Desired output is currently produced by:

```
pandoc 1.17.1
PHP Markdown Extra 1.2.8
Minima 0.8.0a3_20140907
kramdown 1.2.0
cebe/markdown GFM 1.1.0
cebe/markdown MarkdownExtra 1.1.0
Blackfriday
Earmark 0.2.1
```

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the two pipe-table examples in MacDown and compare the rendering of the escaped-pipe case with the normal table. Trace the Markdown table parsing entry point used by MacDown; done means an escaped pipe in a table cell no longer prevents the table from being recognized, while ordinary table behavior remains unchanged.

Written by the indexing model from the issue text.

Assessment

Tech stack
markdown
Domain
content
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.