how to check header in nodejs express code example
Example 1: set headers in express
response.header("Access-Control-Allow-Origin", "*");
response.header("Access-Control-Allow-Headers", "Origin, X-Requested-With,Content-Type, Accept");
response.header('Access-Control-Allow-Methods', 'GET,PUT,POST,DELETE')
Example 2: hwo to cehck req header in js
var host = req.headers['host'];