check_header
v1.1.0
Published
Check if headers aren't invalid for correct use in setHeader or writeHead functions
Downloads
49
Readme
Check Header
Code is inherit from NodeJS internal functions introduced in v0.10.42, v0.12.10, v4.3.1 and v5.6.0.
Install
npm install --save check_header
Example
var checker = require('check_header');
var headersObject = {'Content-Type':'žluťoučký kůň'};
if (!checker.isValid(headersObject)) {
console.log("Invalid header there!");
}