This is the simplest from scratch coding exercise to answer "What's the best way to learn to code if you know nothing?".
The goal is to create a simple web page that displays the text "Hello World!".
The page should be valid HTML5 and should be styled with CSS.
The page should be built from scratch, without using any frameworks or libraries.
Play around by adding HTML elements and CSS styles.
You don't need JavaScript yet.
Here are the steps to follow, use the code in this repo as a reference:
- Download VSCode
- New file
index.html
- Open it in your browser
- Lay out a basic webpage, use
<html>
,<body>
,<head>
and<div>
(search what they mean as you go) - Add some text elements, like
<h1>
and<p>
- New file
style.css
- Link to it in
index.html
(search to find out how) - Add
body { background: black; color: white; }
tostyle.css
- Refresh
index.html
in your browser to see the effect your changes have had - Add more HTML elements and CSS styles