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

Strip trailing newlines in unhighlighted code blocks #528

Conversation

nicoburns
Copy link
Contributor

Fixes #527.

It is possible to apply a similar fix to math code blocks, but I was unsure whether that was a correct change as I'm not using math code blocks so I have not included that change here.

@kivikakk
Copy link
Owner

Trailing newlines are actually per spec; see CommonMark § 4.5, and the spec failure in CI.

@nicoburns
Copy link
Contributor Author

Hmmph! Annoying, but it seems like you're correct (and I guess it does make some sense). I think I will need to enable highlighting to get solve this issue in my app.

@nicoburns nicoburns closed this Jan 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unhighlighted code blocks contain invalid trailing newlines
2 participants