Lesson 22. Capstone: Hangman game
In this capstone you’re going to build a hangman game. The game will incorporate a status message, letter slots for the word, and buttons for guessing letters (figure 22.1).
You’ll start your project using the start folder included in the code accompanying this book. If at anytime you get stuck, you can also check out the final folder with the completed game. The start folder is a project already set up to use Babel and Browserify (see lessons 1–3); you just need to run npm install to get set up. If you haven’t read lessons 1–3, you should before doing this capstone. There’s also an included index.html file: this is where the game will run. It already includes all the HTML and CSS it needs; you just need to open it in a browser once you bundle your JavaScript files. The src folder is where you’ll put all your JavaScript files, and the dest folder is where the bundled JavaScript file will go after you run npm run build.