Skip to content

Tag: express

How does the const a = express() works exactly?

I recently started learning Node/express. One doubt is bugging me for a couple of weeks now. I know what this does, and I’ve been able to get past it. But I cannot wrap my head around the logic used in the line const a = express(). I don’t think I have seen this before in javascript. In this case,…

How to log user input with Morgan?

Good morning, I am trying to log user input from user when using morgan and express. What I am specifically trying to log is noted in this image: (The user posted a request with an object that includes two key/value pairs “name” and “number”) How would I go about logging this? Custom t…