List item elements (<li>) must be contained within a parent <ul>, <ol>, or <menu> to preserve semantic list structure.
<ul>
<li>First item</li>
<li>Second item</li>
</ul><li>First item</li>
<li>Second item</li>When: A list item appears outside a <ul>, <ol>, or <menu>
Warning: <li> must be inside a <ul> or <ol>
Solution: Wrap <li> elements in a <ul> or <ol>
Accessibility: Mis-nested <li> elements break screen-reader list navigation and disrupt the document’s outline.
SEO: Structured lists help search engines parse content hierarchy and can improve featured snippet eligibility.
Prevent orphaned list items by enforcing proper HTML list nesting, improving accessibility and maintainability.
H48: Using <ol>, <ul> and <dl> for lists or groups of links to ensure proper list semantics.ARIA list: For custom structures, use role="list" and role="listitem" to mimic native list behavior.Each <li> represents an item of its parent list. Outside a valid container, it has no defined list context and should be corrected to maintain the document outline.