Member-only story
CSS Basics
Understanding the Tags in HTML Boilerplate
<!DOCTYPE>, <html>, <head>, <meta>, <title>, <body>, <link>, and <script>
5 min readNov 6, 2019
While some HTML tags are self-explanatory, others are not.
Instead of adding them blindly into your HTML file, how about finding out what they are?
HTML Boilerplate
Let’s go through an HTML boilerplate line by line.
To generate it, we use the shorthand command by typing [ ! ]
+ [ tab ]
on an HTML file opened in a code editor with Emmet.
Line 1
The first thing to do when creating an HTML document is to include a document type definition declaration.
<!DOCTYPE html>
This is used by:
- Browsers to determine whether to render the webpage in standards mode (which is according to CSS specifications) or quirks mode (which is more backwars compatible with old practices and old browsers)
- Markup validators to determine which HTML rules to use when checking through the HTML syntax