Skip to content

Fix Markdown Issue #1204

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
May 12, 2017
Merged

Fix Markdown Issue #1204

merged 2 commits into from
May 12, 2017

Conversation

skipjack
Copy link
Collaborator

Fix issue with escaped | not being taken into account.

This is allowed in GFM but not supported by marked. See this issue:
markedjs/marked#595

Fixes #1187

cc @Alex1990 @NejcZdovc

This is allowed in GFM but not supported by marked. See this issue:
markedjs/marked#595

Fixes #1187

// Fix escaped '|' characters
// See https://github.com/chjj/marked/issues/595
let erroneous = row.map(item => item.endsWith('\\') ? item : null).filter(item => item !== null)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I might write this as

let erroneous = row.map(item => item.endsWith('\\') && item).filter(item => item)

Same result.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

++

@skipjack skipjack merged commit c0266e4 into master May 12, 2017
@skipjack skipjack deleted the fix-gfm-issue branch May 12, 2017 21:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants