-
Notifications
You must be signed in to change notification settings - Fork 75
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
Link in HTML encoded #245
Comments
Yeah, I could swear I worked on this exact thing not too long ago (though it's been a crazy summer for me, so it's also just as likely I'm thinking of something totally different). I'm also wondering if the Markdown parser is getting in the middle and encoding it before I see it (or something related to that process on my end). I'll take a look - I'm assuming you're on the latest version? |
Thanks! Yes, this is with a site built with Statiq.Web 1.0.0-beta.49 |
@daveaglick I can confirm that it is the Markdown parser which is responsible for the behavior. I created a test case in #262 |
Related Markdig issue: xoofx/markdig#514 |
While CommonMark expects Markdown:
Expected HTML output:
Actual HTML output:
I updated #262 to contain a test case, with an link as generated by Statiq.Markdown, which shows that Statiq.Razor renders the link invalid. |
Issue is caused by the use of
|
@daveaglick Not sure what's the best way to proceed here: Currently Statiq.Markdown (Markdig) and Statiq.Razor (TagBuilder) are encoding. We need to get rid of one of those. There's no option for either Markdig or TagBuilder to not encode and would need additional code on either side. IMHO best solution would be to not have it encoded in Statiq.Markdown in cases where Statiq.Razor runs afterwards in the pipeline, but not sure how this can be detected. |
I've a link in a markdown file containing some URL parameters:
When HTML document is generated the link will be URL encoded, resulting in an invalid link:
The text was updated successfully, but these errors were encountered: