DEV Community

Cover image for Less Popular But Essential HTML Tags

Less Popular But Essential HTML Tags

James Sinkala on April 25, 2021

HTML (Hyper Text Markup Language) is the primary markup language that we use to layout web content. For any developer who works within the front-en...
Collapse
 
zilti_500 profile image
Daniel Ziltener

Note that you'll currently need to use a polyfill to use the element. It is so far only out-of-the-box enabled in Chrome. Firefox needs a setting turned on, and Safari doesn't support it.

Collapse
 
mellen profile image
Matt Ellen-Tsivintzeli

Which element?

Collapse
 
zilti_500 profile image
Daniel Ziltener

Whoops, seems like Dev.to's comment formatting swallowed it. I meant <dialog>.

Thread Thread
 
mellen profile image
Matt Ellen-Tsivintzeli

Oh! Thanks, good to know.

Collapse
 
lucasballyn profile image
Lucas Ballyn

Yesterday I learnt about the datalist. Html native select search/autocomplete. developer.mozilla.org/en-US/docs/W...

Collapse
 
gracesnow profile image
Grace Snow

Yeah only issue with that can be that users can also write in their own text so it's not a true autocomplete without a sprinkling of js on top.

I know what you mean though. We recently discovered this one after weeks of work on a custom autocomplete that was basically just this element! Talk about reinventing the wheel

Collapse
 
lucasballyn profile image
Lucas Ballyn

Yes indeed, you're right, Grace!

Collapse
 
breadcrumb profile image
Brando

Wow! I never knew most of these existed! Great article. (:3 」∠)

Collapse
 
xinnks profile image
James Sinkala

Neither did I at some point 🤷🏻‍♂️, glad I brought them into your attention🕵🏼‍♂️.

Collapse
 
gracesnow profile image
Grace Snow

I always forget about dialogue. The rest I use all the time 😎

Bdi was a very recent discovery for me

Collapse
 
gracesnow profile image
Grace Snow

I'm not sure main is a "less popular" element tbh though. That's pretty standard, like header and footer

Collapse
 
xinnks profile image
James Sinkala

Surprising as it is it's not used as much as it should be or we assume it is, especially compared to the header and footer elements. I tried checking a number of random websites including top sites such as Google (results page), Twitter, Instagram🤔, Medium, Geeksforgeeks etc and could not find it in their source code, though some e.g Google use the ARIA role="main" in its place (I guess partly in consideration of IE 11 users).
It is a limited set of data that I've based this on for my lack of knowledge of a better way to collect such stats, but it got me thinking that it just might not be as popular/used as I think it is.

Collapse
 
jashgopani profile image
Jash Gopani

Although some of the outputs are predictable, would have loved some sort of output gif/codepen element in the post :)