If you have (Lists do not contain only <li> elements and script supporting elements (<script> and <template>).)

Screen readers and other assistive technologies depend on lists being structured properly to keep users informed of content within the lists. The only content lists should contain should be within <li> elements. They can also contain script supporting elements (<script> and <template>).

 

How this Lighthouse audit fails 

Lighthouse flags lists that contain content elements that shouldn't be in a list:

 

How to create correctly structured lists 

Remove any elements in lists that don't belong there. Ordered and unordered lists must only contain <li><script> or <template> elements.

Valid lists must have parent elements (<ul> or <ol> elements) and child elements (<li> elements). Any other content elements are invalid.

Was this answer helpful?

Related Articles

If You have (Links do not have a discernible name)

Links do not have a discernible name     Link text that is discernible, unique, and focusable...

If you have (Background and foreground colors do not have a sufficient contrast ratio.)

Text that has a low contrast ratio—that is, text whose brightness is too close to the background...

If you have ( robots.txt is not validLighthouse was unable to download a robots.txt file)

The robots.txt file tells search engines which of your site's pages they can crawl. An invalid...

Powered by WHMCompleteSolution