Yes, if you use ol
you can use the reversed
and start
attributes in the way you described.
But you probably shouldn’t use ol
here.
ol
is not simply for any sorted list. Only use ol
if the order of the li
is important for the (understanding of the) content.
From the ol
definition (bold by me):
The
ol
element represents a list of items, where the items have been intentionally ordered, such that changing the order would change the meaning of the document.
Examples for ol
:
- search engine results (if ranked by relevance)
- a list of favorite things (if ranked by favor)
- a list of blog posts where each post is a chapter of a novel (so users should read them in this (and no other) order)
Examples for ul
:
- search engine results (if there is no ranking algorithm)
- a list of favorite things (if you can’t decide which of those you like more)
- a list of blog posts where each post can be read on its own (i.e. a typical blog)
Even if those last three examples are ordered chronologically or alphabetically, this doesn’t influence the meaning of the content.