Learning NodeJS
These are the activities included in the node sample project that we work on throughout the program. No prior NodeJS experience is required, but you should be comfortable with JavaScript.
Note that this project is not coherent. It's simply a mish-mash of activities to help students learn NodeJS and how it can be used for developing web applications.
Web 2
- Setting up the project
- File IO in NodeJS
- TODO: Make a video that shows how to use the debugger to step through the code.
- A very simple web server
- NPM
- Creating custom modules
- Getting started with Express
- EJS Templates
- The body-parser package
- The user-helpers module
Web 3
- OPTIONAL: Making the user-helpers asynchronous (callback hell)
- HTTP and Form Handling (http-sample-app.js & sample-form.html)
- File Uploads (file-upload.html & file-upload-sample-app.js)
Web 4
- Middleware
- Error Handling
- Environment Variables and dotenv
- Using bcrypt to Hash Passwords
- Cookies
- Sessions
- Organizing Routes into Separate Files
- Unit Testing with Jest - grading-helpers module
- Test-driven Development Assignment - Artist Model Object
- Helmut
- CORS
- Logging
Links to resources (for the Web 4 lessons):
- Using Middleware
- Middleware in Express JS
- Express Error Handling
- Node Error Handling
- Another one on Express error handling
- NODE_ENV (environment variable)
- Unit Testing
- Hashing Securely
- Salting and Hashing
- Express cookies and sessions
- More info on cookies
- Session based authentication
- Storing session data in MySQL
- Securing JavaScript Apps