-
-
Notifications
You must be signed in to change notification settings - Fork 320
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
clarify that character references are not interpreted in HTML blocks and raw HTML #690
base: master
Are you sure you want to change the base?
Conversation
…and raw HTML The wording in section 2.5 implied otherwise, although an example in 6.6 did clarify. Adjust the first to remove the false implication and adjust the second from saying "preserved", which might mean they have to be parsed first, to "copied uninterpreted".
Entity and numeric character references are treated as literal | ||
text in code spans and code blocks: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Entity and numeric character references are treated as literal | |
text in code spans and code blocks: | |
Entity and numeric character references are treated literally | |
in code spans and code blocks: |
I think “text” might be a bit confusing as there’s the connotation with “Textual content”. Characters in this context, is confusing too. So many like this?
Entity and numeric character references are left uninterpreted | ||
in HTML blocks and raw HTML: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Entity and numeric character references are left uninterpreted | |
in HTML blocks and raw HTML: | |
Entity and numeric character references are not interpreted | |
in HTML blocks and raw HTML: |
Personally I think this suggestion is clearer, but I don’t have strong opinions on it.
Entity and numeric character references are recognized in any | ||
any other context, including URLs, [link titles], and | ||
[fenced code block][] [info strings]: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Entity and numeric character references are recognized in any | |
any other context, including URLs, [link titles], and | |
[fenced code block][] [info strings]: | |
Entity and numeric character references are recognized in any | |
other context, including URLs, [link titles], and | |
[fenced code block][] [info strings]: |
Double any
.
@@ -9173,17 +9180,17 @@ foo <![CDATA[>&<]]> | |||
```````````````````````````````` | |||
|
|||
|
|||
Entity and numeric character references are preserved in HTML | |||
Entity and numeric character references are copied uninterpreted in HTML |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Entity and numeric character references are copied uninterpreted in HTML | |
Entity and numeric character references are not interpreted in HTML |
Same as my earlier reasoning.
```````````````````````````````` | ||
|
||
|
||
Backslash escapes do not work in HTML attributes: | ||
Backslash escapes are also copied uninterpreted: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Backslash escapes are also copied uninterpreted: | |
Backslash escapes are also not interpreted: |
@@ -9192,6 +9199,9 @@ foo <a href="\*"> | |||
```````````````````````````````` | |||
|
|||
|
|||
Not interpreting backslash escapes can mean not recognizing | |||
a tag that HTML5 would recognize: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I’m not a fan of this sentence: HTML(5) definitely does recognise this. It’s a “valid” but weird link to \
and an attribute "
(w/o value).
Perhaps better to say something along the lines of:
As backslash escapes are a markdown thing, and not an HTML thing,
they are not interpreted in HTML:
The wording in section 2.5 implied otherwise,
although an example in 6.6 did clarify.
Adjust the first to remove the false implication
and adjust the second from saying "preserved",
which might mean they have to be parsed first,
to "copied uninterpreted".
The diff makes a bit of a hash of the changes,
which are to move the "unrecognized" cases
above the recognized ones, as suggested in #687.
Fixes #687.