Skip to content
This repository has been archived by the owner on Mar 28, 2019. It is now read-only.

allow whitespace to appear before the DOCTYPE #84

Open
kevinbarabash opened this issue Apr 10, 2016 · 2 comments
Open

allow whitespace to appear before the DOCTYPE #84

kevinbarabash opened this issue Apr 10, 2016 · 2 comments

Comments

@kevinbarabash
Copy link

No description provided.

@Pomax
Copy link
Contributor

Pomax commented Apr 10, 2016

based on https://www.w3.org/TR/html-markup/documents.html#conformant-documents spaces and comments should indeed be allow before doctype declarations

@kevinbarabash
Copy link
Author

It looks like fixing this should be too bad. Adding a call to stream.eatSpace() before matching the doctype in HTMLParser's parse method should do the trick. Let me see if I can put together a PR for this.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants