Instructions for the http.response.getHeader method in node.js

  • 2020-05-05 10:52:06
  • OfStack

method description:

Reads the header information that has been queued but not yet sent to the client.

syntax:


response.getHeader(name)

receive parameters:

name                   response header type, note that this name is case insensitive.

example:


var contentType = response.getHeader('content-type');


Related articles: