Skip to content

use custom pandoc writer to preserve raw html blocks #553

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 1 commit into from
Sep 25, 2024

Conversation

gtritchie
Copy link
Collaborator

Fixes #552

Uses a custom pandoc writer to preserve raw HTML blocks ({=html}) when using Visual Editor.

This was due to a Pandoc 3.2+ change that was stripping these blocks when we were converting from the AST to markdown.

Note/question: I updated the CHANGELOG and extension version as part of this; not sure if that's appropriate or should be done separately.

The same change will be made separately in RStudio; it will consume this same md-writer.lua script (rstudio pulls in this repo to obtain panmirror so can grab it from there) and rsession will make the same substitution that is happening here.

Copy link
Collaborator

@juliasilge juliasilge left a comment

Choose a reason for hiding this comment

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

I am not currently able to comment on the visual editor change, but since this does go out with the VS Code extension, we do want to update the changelog for it and this looks good to me. Thanks!

@gtritchie gtritchie merged commit 75359e3 into main Sep 25, 2024
@cderv cderv deleted the fix-raw-html-blocks branch October 1, 2024 13:26
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.

Visual Editor loses raw HTML code blocks
4 participants