Live Coding a JavaScript Poll App with Chris and Alex (1/2)

Watch part 2 with Chris:
Subscribe to Chris’ YouTube channel:

Website we built:
Source code:

▼ Follow me ▼

on Twitter:
on GitHub:

▼ Links I Mention in the Video (in the Order I Mention Them)▼

My Sequelize course
My shell aliases:
My friend Jerrie from ProCoder’s Postman course:

▼ Timestamps▼

For your convince, here are some timestamps:

00:00 Introduction
01:49 Initializing Git
02:32 Creating npm package.json
02:49 Setting up ESLint
04:17 Setting up Babel
07:30 Setting up a simple Express server
08:38 Setting up Nodemon npm script
10:11 Connecting to MySQL via Sequelize
12:50 Installing the Babel parser for ESLint
13:57 Setting up a one-to-many relationship between the poll and poll option tables
19:22 Creating the MySQL database via the MySQL command-line tool
20:54 Creating the poll controller
21:24 Handling poll submissions
29:48 Handling poll queries
33:10 Creating the vote controller
33:17 Setting up the vote model
35:47 Debugging the vote model
37:14 Handling vote submissions
39:58 Including votes in the poll query response
41:39 Coding a more efficient way to query poll votes
43:31 Prevent users from voting on the same poll more than once based on their remote IP
51:28 Creating an error handler middleware function
54:00 Setting up Chalk
54:56 Basic input validation
56:43 Uploading the code to GitHub
58:22 Conclusion

▼ Attribution ▼

Intro inspiration by Mackenzie Child

Emoji provided free by

Sound effect provided free by

Twitter and GitHub icons provided free by Freepik form

Link icon provided free by Dave Gandy from via

Special thanks to Cruor ( and Yngve Olsen Ranestad ( who helped me with a SQL query when preparing for this video.



Do NOT follow this link or you will be banned from the site!