express-intro Flashcards

1
Q

How do you add express to your package dependencies?

A

npm install express

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What Express application method starts the server and binds it to a network PORT?

A

the listen method

  1. const express = require(‘express’);
  2. const app = express();
  3. app.listen(port, () => {do something when server starts});
How well did you know this?
1
Not at all
2
3
4
5
Perfectly