3 ms·
What would be even better is this: ul li:nth-child(-n + 3) { background: red; } See the last example on this page: https://developer.mozilla.o
by JelteF 10y ago
What would be even better is this:
ul li:nth-child(-n + 3) {
background: red;
}
See the last example on this page: https://developer.mozilla.org/en-US/docs/Web/CSS/:nth-child https://developer.mozilla.org/en-US/docs/Web/CSS/:nth-child