Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

AlexKamaev/node-no-proxy

Open more actions menu
 
 

Repository files navigation

no-proxy

Test URL against NO_PROXY environment variable.

console.log(process.env.NO_PROXY); // ".foo.com,*.bar.com,10.*,192.168.1."

// requires protocol
var noProxy = require('no-proxy');
noProxy('http://foo.com/'); // true
noProxy('http://www.baz.com/'); // false

// check hostname part only
var noProxyHost = require('no-proxy/hostname');
noProxyHost('foo.com'); // true
noProxyHost('baz.com'); // false
noProxyHost('192.168.1.1'); // true

NOTE: You may want to use memoization around this module.

WARNING

If you are using a node version prior to Node 8, you need to install url-parse as a dependency.

About

Use test URL against NO_PROXY

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%
Morty Proxy This is a proxified and sanitized view of the page, visit original site.