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 wrong highlight in CRLF #240

Merged
merged 3 commits into from
May 18, 2021
Merged

Fix wrong highlight in CRLF #240

merged 3 commits into from
May 18, 2021

Conversation

yhatt
Copy link
Member

@yhatt yhatt commented May 18, 2021

Fix #239.

  • The current YAML parser (yaml) removes CR in the normalize process. So we will use yaml@next (& normalize trailing CR of the passed text to prevent parse error)
  • HTML comment parser (rehype) returns the comment node with normalized value. To pass the raw text including CR into YAML parser, we have to pick substring from HTML sourcemap manually.

@yhatt yhatt merged commit 0e0e0ba into main May 18, 2021
@yhatt yhatt deleted the directive-parser-crlf branch May 18, 2021 19:01
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.

Wrong highlight in CRLF
1 participant