About 689,000 results
Open links in new tab
  1. What are "res" and "req" parameters in Express functions?

    323 req is an object containing information about the HTTP request that raised the event. In response to req, you use res to send back the desired HTTP response. Those parameters can …

  2. Node.js: Difference between req.query [] and req.params

    Oct 3, 2019 · Is there a difference between obtaining QUERY_STRING arguments via req.query[myParam] and req.params.myParam? If so, when should I use which?

  3. what is the purpose of req.body in express.js? - Stack Overflow

    May 16, 2021 · It contains the body of the request. Express provides body parsers. If the body is JSON data it's parsed and you can access the elements, e.g. req.body.name and …

  4. how to get request path with express req object - Stack Overflow

    Sep 21, 2012 · req.path was already doing exactly same thing that I mentioned here. I don't remember how this answer solved issue and accepted as a correct answer but currently it's …

  5. node.js - Sending an array of values through the query parameters …

    I need to create url for get which is going to accept array, how in node.js/express extract array from request ? I need to pass array with names which parametes I need to back from Person …

  6. How to access the GET parameters after "?" in Express?

    Jun 9, 2013 · req.params req.body req.query Note the guide does state the following: Direct access to req.body, req.params, and req.query should be favoured for clarity - unless you truly …

  7. node.js - req.query and req.param in ExpressJS - Stack Overflow

    Main differences between req.query and req.param in Express How are Both different from each other When to use then in what cases Suppose a client sends say Android (Key,value) pair in …

  8. Extend Express Request object using Typescript

    May 23, 2016 · I’m trying to add a property to express request object from a middleware using typescript. However I can’t figure out how to add extra properties to the object. I’d prefer to not …

  9. node.js - Difference between req.url and req.originalUrl in …

    From the Express.js documentation: req.url is not a native Express property, it is inherited from Node’s http module. This property is much like req.url; however, it retains the original request …

  10. How to determine a user's IP address in node - Stack Overflow

    Nov 13, 2011 · Using req.connection.remoteAddress to get the client IP might still work but is discouraged. Luckily, has been there since [email protected] and is a perfect replacement: