Codele / How software is built
JavaScript in the page
HTML is the skeleton and CSS is the clothes. JavaScript is the muscles: it waits for something to happen, then changes the page.
- JavaScript makes a page react. HTML and CSS alone cannot.
- An event is something that happens, such as a click or a key press.
- A handler is code that waits for an event and runs when it happens.
- The memory box keeps the number. Changing the box does not change the page by itself.
- The handler must also write the new number onto the page.
Loading the playable lesson…