There are well over 100 HTML tags. We all know the basics such as div, p, img. But here are three dynamic tags you probably didn't know about.
The Progress Tag
- The "progress" tag is an easy way to display a progress bar using only HTML. Of course, you can also update the value with JavaScript and move it.
<progress value="30" max="100">30%</progress>
The Details Tag + Summary Tag = Accordion
- If you use the "Details" and "Summary" tags together, you'll get a very simple accordion right out of the box, without the need for JS at all.
<details>
<summary>Now open the accordion</summary>
And here is the accordion body
</details>
Abbreviation (abbr)
- You can use the "abbr" tag to add notes to the abbreviation. Very useful when writing technical content with many shortcuts that we usually take for granted.
<abbr title="World Health Organization">WHO</abbr> was founded in 1948.
Thanks for following along and would love to have a feedback of how this helped you.
Top comments (0)