Open evanorsouw opened 7 years ago
Please post the source of a document or document fragment that causes this error to be emitted
Mostly likely this is reported because the document has something like this:
<p>
<ul>
…
</ul>
</p>
In that case what that document really looks like, as seen by an HTML parser, is this:
<p></p>
<ul>
…
</ul>
</p>
That’s because, the way HTML works is, a <ul>
start tag implies a </p>
close tag for any open p
elements.
I feel like a FAQ for "p was implicitly closed by open tag of element disallowed by p's content model, thus making the explicit p close tag unmatched" is merited at this point. It seems to come up frequently on the issue tracker. Maybe with a link to other linter(s) that give more comprehensible error messages in that case.
Chris, you hit the spot right on. <p><ul></ul></p>
is exactly what the html looks like.
I guess there is a lot of html legacy at play, so I am fine with your explanation.
Your suggestion to somehow improve the error message seems valid to prevent wasting time in the future as much as possible.
Thx for the swift response.
Erm, Michael was the one who diagnosed your problem.
ah yeah, my bad, thanks michael.
When checking the site whitemagic.it the following error is reported;
It appears this is an invalid error.