rayd / html-parse-stringify2

Parses well-formed HTML (meaning all tags closed) into an AST and back. quickly.
21 stars 11 forks source link

Fix void elements #8

Closed markhalliwell closed 7 years ago

markhalliwell commented 7 years ago
markhalliwell commented 7 years ago

Not really sure why the tests are failing, but it's not because of these changes...

rayd commented 7 years ago

Sorry for the huge delay on these PRs your submitted @markcarver! I appreciate the work you put in! Made a couple tweaks to things based on some submitted issues and reading over the HTML spec. For this one, it seemed like we ought to support handling tags that declare themselves as self-closing as "void elements" in the parser, since the spec allows one to declare "foreign elements" that can be self-closing.