๐Ÿ› ๏ธ How This Site Works

The story of how jonahdotcom.com was built!

Wait... how does a website even work? ๐Ÿค”

Great question! Think of building a website like building a LEGO house.


You need three things:


Every website you've ever visited โ€” YouTube, Minecraft.net, NFL.com โ€” is made of these same three things!

๐Ÿงฑ HTML โ€” The Bricks

HTML stands for HyperText Markup Language. That's a big fancy name, but it just means: "instructions for building a webpage."


HTML uses things called tags. Tags are like labels that tell the browser what each thing is.


For example, this site uses tags like:


Every tag has an opening part and a closing part. Like a sandwich ๐Ÿฅช:


<p> Hi, I'm Jonah! </p>


The <p> is the top bread, the text is the filling, and </p> is the bottom bread. The slash ( / ) means "end of tag."

๐ŸŽจ CSS โ€” The Paint

CSS stands for Cascading Style Sheets. It's the code that makes everything look cool instead of plain and boring.


Without CSS, this site would just be white with black text โ€” like a printout from 1995.


CSS is what gives this site:


CSS works by saying "find this thing, and make it look like this." For example:


button {
  background: red;
  color: white;
}


That tells the browser: "every button should have a red background and white text."

โšก JavaScript โ€” The Motor

JavaScript is what makes a website do things. HTML and CSS just sit there โ€” JavaScript reacts when you click, type, or move your mouse.


On this site, JavaScript powers the football facts button on the home page. Here's how it works:


"Random" in code is like rolling a dice ๐ŸŽฒ โ€” the computer picks a number and uses it to choose a fact from the list.


JavaScript can also do math, remember things while you're on the page, and talk to other computers on the internet. Pretty powerful!

๐ŸŒ How Does It Get on the Internet?

So we have the code โ€” but how does someone in another state visit jonahdotcom.com?


It takes three steps:


Step 1 โ€” GitHub ๐Ÿ™

The code lives on a website called GitHub. Think of GitHub like a super-powered save file for code. Every time we make a change and "push" it, GitHub saves the new version. It keeps every old version too, so we can never mess up permanently!


Step 2 โ€” GitHub Pages ๐Ÿ“„

GitHub has a free feature called GitHub Pages that takes our code and puts it on the internet automatically. It's like GitHub saying: "I'll keep your LEGO build on display so everyone can see it."


Step 3 โ€” The Domain ๐Ÿ 

A domain is your address on the internet. Without an address, no one knows where to find you! We bought jonahdotcom.com so that when anyone types that in, their browser knows exactly where to go.


When you type jonahdotcom.com into a browser, here's what happens in about half a second:

๐Ÿ‘จโ€๐Ÿ’ป Who Built This?

This site was built by Jonah and his dad as a fun project to learn how websites work.


It was built using:


Total cost to build: about $10 a year โ€” just for the domain name. Everything else was free! ๐ŸŽ‰


If Jonah can build a website at 9 years old, so can you. ๐Ÿš€