Skip to content
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

Fix lexer and tokenizer to retain line breaks properly #2341

merged 6 commits into from Jan 6, 2022


Copy link

@phillipb phillipb commented Dec 31, 2021

Marked version:

Markdown flavor: n/a


This PR stops ignoring single \n characters and makes sure they're properly represented in the token list for each token type in the lexer.


  • Test(s) exist to ensure functionality and minimize regression (if no tests added, list tests covering this PR); or,


In most cases, this should be a different person than the contributor.

Copy link

@vercel vercel bot commented Dec 31, 2021

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect:

test/unit/Lexer-spec.js Outdated Show resolved Hide resolved
UziTech approved these changes Jan 4, 2022
Copy link

@UziTech UziTech left a comment

Thanks for working on this! 💯

styfle approved these changes Jan 6, 2022
@UziTech UziTech merged commit a9696e2 into markedjs:master Jan 6, 2022
9 checks passed
github-actions bot pushed a commit that referenced this issue Jan 6, 2022
## [4.0.9](v4.0.8...v4.0.9) (2022-01-06)

### Bug Fixes

* retain line breaks in tokens properly ([#2341](#2341)) ([a9696e2](a9696e2))
Copy link

@github-actions github-actions bot commented Jan 6, 2022

🎉 This PR is included in version 4.0.9 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
Linked issues

Successfully merging this pull request may close these issues.

3 participants