Closed MeirionHughes closed 4 years ago
+1
I also found this which is useful:
The following is a complete list of the void elements in HTML: area, base, br, col, command, embed, hr, img, input, keygen, link, meta, param, source, track, wbr
https://www.w3.org/TR/html-markup/syntax.html#syntax-elements
Currently HTMLHint doesn't complain if you self-close any element. We had an issue in one of our projects where there was a self-closing textarea
which caused some really weird behavior during minification and runtime.
Thus it would be great if we could have a rule that would cause a warning for any self-closing tag that isn't in the list of void tags above.
Just wanted to say that we've had a similar issue, where htmlhint failed to correctly mark <div />
as invalid.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
https://www.w3.org/TR/html-markup/syntax.html#syntax-elements
So custom tags webcomponents must have an end tag and cannot self-close.
example
htmlhint --rules tag-pair
should fail in htmlhint (currently does not)
should pass in htmlhint (currently does)