This lesson picks up where the last one left off and has you creating the rest of your views. You’ll be focusing on the forms needed to create and update new entries in your database. With the knowledge you pick up here, you’ll really be ready to go create your own data-driven web applications. There is, of course, more to learn, but finishing this one is a big step towards actually being able to do your own projects.
It’s another long multi-part tutorial, with plenty of useful information scattered throughout. Be sure to take your time and read everything!
This is the last lesson on the MDN tutorial. The last step, listed below takes you through what you need to do to actually deploy your project so you can share it and show it off, so be sure to link it up in the student solutions below!
By the end of this lesson, you should be able to do the following:
- Describe form handling process.
- Describe validation and sanitization.
- Describe routes.
- Work with HTML forms in Express using Pug.
- Use forms to get data from users and update the database with this data.
- Validate and sanitize input using express-validator.
- Write forms to create, update, and delete records from the database.
- Add basic forms and form-handling code to Node websites.
Reminder: Make sure to hide your MongoDB connection URL! Once you’ve hosted your app on Railway you’ll be creating a new database with them and can use the instructions in the MDN tutorial to manage environment variables through the Railway dashboard.