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
- A Very Simple Web Server
- NPM
- Creating Custom Modules
- Getting Started with Express
- EJS Templates
- The body-parser Package
- OPTIONAL: The user-helpers module
- OPTIONAL: Unit Testing with Jest
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)
- OPTIONAL: Test-driven Development Assignment - Artist Model Object
Web 4
- Middleware
- Error Handling
- Logging
- Environment Variables and dotenv
- Using bcrypt to Hash Passwords - Note: The users-helpers module must be completed before doing this actvity
- Cookies
- Sessions
- Organizing Routes into Separate Files
- Unit Testing with Jest - grading-helpers module
- Test-driven Development Assignment - Artist Model Object
- Helmut
- CORS
- Logging
- Documenting your API
Links to resources (for the Web 4 lessons):
- Using Middleware
- Middleware in Express JS
- Optimizing Middleware
- 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
- Documenting your API