Skip to content

Commit

Permalink
Switch to <ol> for breadcrumb
Browse files Browse the repository at this point in the history
The Breadcrumb Glossary page notes

> _Note: While there's no dedicated semantic HTML element for breadcrumb navigation menus, the <ol> element is commonly used to represent their hierarchical structure._

I suggest following our own advice. From a semantically standpoint, it just makes to use an ordered list.
  • Loading branch information
lescx authored Dec 19, 2024
1 parent c872bb2 commit 44affc8
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,13 @@ Click "Play" in the code blocks below to edit the example in the MDN Playground:

```html live-sample___breadcrumb-example
<nav aria-label="Breadcrumb" class="breadcrumb">
<ul>
<ol>
<li><a href="#">Home</a></li>
<li><a href="#">Category</a></li>
<li><a href="#">Sub Category</a></li>
<li><a href="#">Type</a></li>
<li><span aria-current="page">Product</span></li>
</ul>
</ol>
</nav>
```

Expand Down

0 comments on commit 44affc8

Please sign in to comment.