Use semantic HTML elements like nav
over creating your own with roles, etc.
Native elements have more built-in than just a role
, they feature keyboard accessibility, state, etc. As an example, think of a <button>
vs role="button"
.
A full list of implicit ARIA semantics can be found in https://www.w3.org/TR/html-aria/