So far we have been creating little bits of html. Now let’s create a whole document.
<!DOCTYPE html> <html> <head> <title>A demo page</title> </head> <body> Your page goes here </body> </html>
This is an HTML5 doctype. It tells the browser what type of HTML we are using. The HTML5 doctype is the only doctype you should be using at the moment.
This tag wraps the entire document. We call it the root tag. Any tree we draw will have this as it’s root.
This is your page body, the part of the page that will be rendered on the screen.
All the code we have written so far, all your h1, p, table, el, etc tags go in here.
You are going to create a little page on any topic you like. Don’t worry that it doesn’t look pretty yet, we’ll get to that soon.