The Web Developer Bootcamp 2024

Colt Steele

Back to Express Index Page


 

Express Js
What is Express

Express.js, often referred to simply as Express, is a minimal and flexible web application framework for Node.js that simplifies the development of web applications and APIs. It provides a robust set of features for building dynamic web applications and APIs, making it one of the most popular frameworks for server-side web development.

Express is designed to be unopinionated, allowing developers to choose the most suitable tools and approaches for their projects. It supports various middleware for handling requests, parsing data, and managing sessions, among other tasks. Additionally, Express is known for its routing capabilities, which enable developers to define how an application responds to client requests at different URLs and HTTP methods.

Express helps us to:

  1. Start up a server and listen for responses.
  2. Parse incoming requests.
  3. Match those requests to particular routes.
  4. Craft our HTTP response and associated content.

Express is a Framework. So far, what we have been working with are packages, which are also referred to as Libraries. So what are the differences between Frameworks, and a Libraries?

The primary difference between JavaScript libraries and frameworks lies in the concept of inversion of control:

  • ∴  When you use a library, you are in charge of the flow of the application, deciding when and where to call the library functions.
  • ∴  Conversely, a framework inverts the control of the program, providing some places for you to plug in your code, but it calls the code you plugged in as needed.


Back to Top