counter-reset
The counter-reset
property allows for automatic numbering of elements. Like an ordered list (<ol
) element.
article {
counter-reset: section;
}
section {
counter-increment: section;
}
section h2:before {
content: counter(section) '. ';
}
The counter-reset
property is used …