env-proxy-agent

0.1.0 • Public • Published

env-proxy-agent

Maps environment variables to http.Agent implementations using proxy-from-env and proxy-agent.

Example

import fetch from 'node-fetch';
import envProxyAgent from 'env-proxy-agent';

const endpoint = 'https://api.github.com/graphql';
fetch(endpoint, {
  agent: envProxyAgent(endpoint),
});

/env-proxy-agent/

    Package Sidebar

    Install

    npm i env-proxy-agent

    Weekly Downloads

    3

    Version

    0.1.0

    License

    MIT

    Last publish

    Collaborators

    • jayjaycross