Skip to content
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

Make sure </script>, </pre> and </style> cannot open an HTML block #517

Closed
wants to merge 1 commit into from

Conversation

mgeier
Copy link
Contributor

@mgeier mgeier commented Jan 10, 2018

This is a fun one, because it will break most parsers, see babelmark2.

Or am I mistaken?

@jgm jgm added this to the 0.29 milestone Mar 22, 2019
@jgm
Copy link
Member

jgm commented Mar 22, 2019

I don't think these should be parsed as inline, but I agree that's what the spec says (and you're right that the reference parsers don't do it this way).

I think we should allow close tags for script, pre, and style to satisfy start condition 7.
That is:

  1. Start condition: line begins with a complete [open tag]
    (with any [tag name] other than script, style, or pre)
    or [closing tag]
    followed only by [whitespace]
    or the end of the line.

@mgeier
Copy link
Contributor Author

mgeier commented Mar 25, 2019

I don't know if that would have any obscure consequences, but from what I can tell that sounds very reasonable.

@jgm jgm closed this in b27b9ea Mar 26, 2019
@mgeier mgeier deleted the open-with-closing-tag branch March 26, 2019 08:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants