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

Use of footnotes causes HTML5 validation error #4433

Closed
jonbeebe opened this Issue Feb 21, 2018 · 4 comments

Comments

Projects
None yet
2 participants
@jonbeebe

jonbeebe commented Feb 21, 2018

If footnotes are used in Markdown (which is very common), Hugo renders the anchor with rel="footnote" and this causes an HTML5 validation error:

Bad value footnote for attribute rel on element a: The string footnote is not a registered keyword.

Suggested fix is to use data-rel instead of rel. Any HTML that is generated directly by Hugo (and not from user-supplied templates) should always be valid.

@bep

This comment has been minimized.

Member

bep commented Feb 21, 2018

HTML5 validation error

What validator are you using?

@jonbeebe

This comment has been minimized.

jonbeebe commented Feb 21, 2018

@bep I am using the W3C Markup Validation Service: https://validator.w3.org/#validate_by_input

This page shows the valid values for rel:
http://microformats.org/wiki/existing-rel-values#HTML5_link_type_extensions

@bep bep added Bug Upstream labels Feb 21, 2018

@bep

This comment has been minimized.

Member

bep commented Feb 21, 2018

A fix for this was committed upstream just 3 days ago:

russross/blackfriday@55d61fa

I will verify that we're at latest BF.

@bep bep added this to the v0.37 milestone Feb 21, 2018

@jonbeebe

This comment has been minimized.

jonbeebe commented Feb 21, 2018

@bep Great thanks! Very fast response.

@bep bep closed this in 492fea7 Feb 21, 2018

bep added a commit that referenced this issue Feb 21, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment