Fix inline <code> escaping in reference pages#1164
Merged
ksen0 merged 5 commits intoprocessing:mainfrom Mar 4, 2026
Merged
Conversation
17 tasks
Contributor
Author
|
@ksen0 just a gentle ping on this PR when you have time. All checks are passing. Please let me know if any changes are needed. Thanks! |
Member
|
Hi @rakesh2OO5, this change looks good! Thanks for fixing, and for your patience. Will merge this PR now |
Contributor
Author
|
@ksen0 thanks for the review! Just a quick ping in case the merge step was missed. |
Member
|
@reshma045 ah, sorry, yes, thanks for the ping |
Member
|
@rakesh2OO5 Could you make the same change in a PR targeting the 2.0 branch as well please? I have some merge conflicts with my normal cherry-pick method. (The 2 branches are quite different, that's part of what bottlenecks merging on this repository. The aim is to normalize them a bit more in a few months.) |
Contributor
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #1163
Escaping was not being lost during reference data generation (confirmed in the main p5.js repo). The generated docs/reference/data.json already contains properly escaped HTML.
The issue occurred during rendering in p5.js-website, where inline code containing HTML was being reinterpreted and losing escaped entities.
This PR enables xmlMode in Cheerio within escapeCodeTagsContent to ensure escaped entities inside inline code are preserved.
Multiline pre/code blocks remain unaffected.
Tested locally on affected reference pages including createDiv, attribute, center, and child.