fix(og): decode xml tags in og images#1923
Open
WarningImHack3r wants to merge 1 commit intosveltejs:mainfrom
Open
fix(og): decode xml tags in og images#1923WarningImHack3r wants to merge 1 commit intosveltejs:mainfrom
WarningImHack3r wants to merge 1 commit intosveltejs:mainfrom
Conversation
|
@WarningImHack3r is attempting to deploy a commit to the Svelte Team on Vercel. A member of the Team first needs to authorize it. |
WarningImHack3r
added a commit
to WarningImHack3r/svelte-changelog
that referenced
this pull request
Apr 11, 2026
Bring in improvements from sveltejs/svelte.dev#1923
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.
Fix OG images containing
<s (among others) displaying text with escaped characters (<).This fix is taken directly (and adapted) from the code I wrote in Svelte Changelog (here then here), as we use the same core logic and I encountered the exact same issue. :D
Notes on the code
escape.jsfile to add in my (opposite) logic, which is exactly made for this purpose (lucky me!). In the existing code, I lifted the regex out of the function so it can be computed only once, and made it dynamic so that everything derives from the single existing record. I also added more characters to the record. Finally, I added anullcheck to the existing function to avoid any problem, even though it'll very likely never be used!Note
The CI lint step fails because of the same problem existing on
master, I can't do much about it :(Before submitting the PR, please make sure you do the following
feat:,fix:,chore:, ordocs:.