Lesson 9. Routing in Express.js

In lesson 8, I introduced Express.js as a framework for Node.js web applications. The rest of this unit is dedicated to exploring Express.js functionality and using its convenient methods. This lesson covers routing and how a few more Express.js methods allow you to send meaningful data to the user before building a view. You also walk through the process of collecting a request’s query string. The lesson ends by touching on the MVC design pattern.

This lesson covers

  • Setting up routes for your application
  • Responding with data from another module
  • Collecting request URL parameters
  • Moving route callbacks to controllers
Consider this

You want to build a home-page view for your recipe application that ...

Get Get Programming with Node.js now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.