CSS: Select first x items

Because I keep forgetting this, an entry on the blog so that my future self can find it back easily: CSS: Want your first 5 list items to be bold? li:nth-of-type(-n + 5) {font-weight: bold;} Start with the # of list items you want to impact, then increment backward with -n. — Estelle Weyl (@estellevw) …


This content originally appeared on Bram.us and was authored by Bramus!

Because I keep forgetting this, an entry on the blog so that my future self can find it back easily:


This content originally appeared on Bram.us and was authored by Bramus!


Print Share Comment Cite Upload Translate Updates
APA

Bramus! | Sciencx (2022-06-21T11:39:29+00:00) CSS: Select first x items. Retrieved from https://www.scien.cx/2022/06/21/css-select-first-x-items/

MLA
" » CSS: Select first x items." Bramus! | Sciencx - Tuesday June 21, 2022, https://www.scien.cx/2022/06/21/css-select-first-x-items/
HARVARD
Bramus! | Sciencx Tuesday June 21, 2022 » CSS: Select first x items., viewed ,<https://www.scien.cx/2022/06/21/css-select-first-x-items/>
VANCOUVER
Bramus! | Sciencx - » CSS: Select first x items. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2022/06/21/css-select-first-x-items/
CHICAGO
" » CSS: Select first x items." Bramus! | Sciencx - Accessed . https://www.scien.cx/2022/06/21/css-select-first-x-items/
IEEE
" » CSS: Select first x items." Bramus! | Sciencx [Online]. Available: https://www.scien.cx/2022/06/21/css-select-first-x-items/. [Accessed: ]
rf:citation
» CSS: Select first x items | Bramus! | Sciencx | https://www.scien.cx/2022/06/21/css-select-first-x-items/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.