DEV Community

Let's write HTML like a pro 😎

Yaser Adel Mehraban on September 03, 2019

How often have you wrote a block of HTML without realising the code you've written might not be ideal? The why HTML has always been tha...
Collapse
 
comandeer profile image
Tomasz Jakut

On the other hand, tags like i and b do not represent semantics.

It's no longer true. De facto all elements in HTML are semantic, including also b, i and u, e.g b represents

a span of text to which attention is being drawn for utilitarian purposes without conveying any extra importance and with no implication of an alternate voice or mood

Additionally W3schools is not affiliated with W3C:

The site derives its name from the World Wide Web (W3), but is not affiliated with the W3C.

And TBH their content is much worse than MDN's, e.g. they claim that DOCTYPE tells the browser which version of HTML was used to create the page and that DTD is needed to parse HTML4 correctly. Both of these statements are false: DOCTYPEs are needed only to activate rendering in standards-compliant mode and DTDs aren't used at all, as all rules of parsing HTML are described in details in specification. There are many more errors like this one on W3Schools, so basically it's better to link to MDN instead.

Collapse
 
yashints profile image
Yaser Adel Mehraban

Thanks

Collapse
 
abbiranjan profile image
Alok Ranjan

Very Nice and informative content.
Thanks a lot.

Collapse
 
pikarrypham profile image
Phạm Ngọc Thùy Trang

Wonderful! It can help me to prepare a lot before interviewing. I hope you can write more posts like this.

Collapse
 
yashints profile image
Yaser Adel Mehraban

Thanks Pham, I will for sure

Collapse
 
vlasales profile image
Vlastimil Pospichal
Collapse
 
jsalinas11 profile image
Jordan

I like how this is more of an overview and offers links to dive deeper into various points. It's a nice way to pack in a lot of information without being overwhelming. Nice work!

Collapse
 
yashints profile image
Yaser Adel Mehraban

Thanks Jordan 😊

Collapse
 
andrewbrooks profile image
Andrew Brooks 👨‍💻

Honestly I often have the nagging feeling that my HTML markup could be better. Thanks for sharing your insights! Bookmarked.

Collapse
 
yashints profile image
Yaser Adel Mehraban

Totally relatable, that's why I decided to write about it

Collapse
 
isajal07 profile image
Sajal Shrestha

It's really important to revise the things we've learned and this is quite enough HTML revision. Thanks, Yaser.

Collapse
 
yashints profile image
Yaser Adel Mehraban

True, and you're welcome