I bet you didn't know about these 15 HTML features.

Probably…

Arsen Shkenza
CodeX
5 min readOct 21, 2022

--

An owl working in his computer late at night outside with a view full of stars.

In the last few years front-end development has revolutionized, becoming more efficient, faster and of course larger. The introduction of SPA frameworks made breaking changes to web development. More of the heavy lifting was switched to the front end with more things to take care of such as dynamic UI, routing, state management, etc. Hence programmers are accustomed to new approaches and third parties to alleviate some of the heavy liftings. Of course, it has its advantages, but it sure makes us lazier. But what if I told you that during this period of progress in front-end, you have probably missed some basic features, and instead of using them, you are using third-party packages or even worse, custom styles to achieve basic stuff?! Yes absolutely, let's start from the basics with 15 features you probably didn’t know existed in HTML and will help you achieve a friendly UI with little effort. Without further ado, enjoy!

1. Content Editable

contenteditable is an attribute that can be set on an element to make the content editable. It works with elements like DIV, P, UL, etc. You have to specify it like, <element contenteditable=”true|false”>.

2. Details Tag

The <details> tag provides on-demand details to the user. By default, the widget is closed. When open, it expands and displays the content within.

The <summary> tag is used with <details> to specify a visible heading for it.

3. Datalist

The <datalist> tag specifies a list of pre-defined options and provides an autocomplete feature.

4. Range

The range input type behaves like a slider range selector.

5. Meter

The <meter> tag defines a scalar measurement within a defined range or a fractional value.

6. Progress

The <progress> tag represents the progress of a task.

7. Color picker

A simple color picker.

8. Mark content

Use the <mark> tag to highlight any text content.

9. Blockquote & Cite

If you’re including content from a different source, you should absolutely cite that source.

10. Abbreviation

“abbr” is short for abbreviation! The idea here is that if you use a title (e.g. “Mr.”) or acronym (e.g. “SHIELD”), the abbr tag indicates exactly what that abbreviation means.

11. <del> and <ins>

There is actually a tag for a text that is struck-through and another that indicates the replacement text.

12. Output

The <output> tag represents the result of a calculation. Typically this element defines an area that will be used to display text output from some calculation.

13. Hidden

When it comes to hiding elements, we all tried different approaches such as using opacity:0, visibility:hidden, height:0; width:0, display:none in our CSS file. Each one has its own use cases and works on different layouts. Another option similar to them is the hidden HTML attribute. If an element has hidden specified on it, it’ll be hidden. It happened to me to have hidden inputs for storing values, so don't be surprised if you will need it too!

14. Time

The <time> tag defines a specific time (or datetime).

The datetime attribute of this element is used to translate the time into a machine-readable format so that browsers can offer to add date reminders through the user's calendar, and search engines can produce smarter search results.

15. Audio

The <audio> tag will define a sound and there are three supported files which the tag can be used with. These are MP3, WAV, and OGG. A browser will then select the first one it supports.

That’s it! Please share this blog post to spread knowledge.

Add me on Linkedin if you found this article interesting :D

--

--

Arsen Shkenza
CodeX

Human. | Co-Founder at better. | Front-end architect.