verify element content model (element-permitted-content)

HTML defines what content is allowed under each type of element.

Rule details

Examples of incorrect code for this rule:

<!-- <li> is only allowed with <ul> or <ol> as parent -->
<div>
    <li>foo</li>
</div>
error: Element <li> is not permitted as content in <div> (element-permitted-content) at inline:3:6:
  1 | <!-- <li> is only allowed with <ul> or <ol> as parent -->
  2 | <div>
> 3 |     <li>foo</li>
    |      ^^
  4 | </div>


1 error found.

Examples of correct code for this rule:

<ul>
    <li>foo</li>
</ul>