docs: add proxy configuration for Bun and Deno#539
Conversation
Co-authored-by: pi0 <5158436+pi0@users.noreply.github.com>
Co-authored-by: pi0 <5158436+pi0@users.noreply.github.com>
|
Co-authored-by: pi0 <5158436+pi0@users.noreply.github.com>
Made the documentation more compact and simple in f39d26d. The section now has:
Regarding the semantic title - I can't update the PR title directly, but suggest: "docs: add proxy configuration for Bun and Deno" |
README.md
Outdated
| }); | ||
| ``` | ||
|
|
||
| **Deno** and Bun respect `HTTP_PROXY` and `HTTPS_PROXY` environment variables. Deno can also use undici with npm specifiers for programmatic configuration. |
There was a problem hiding this comment.
@copilot Move this note to first of proxy support section as an > [IMPORTANT] bot and mention Node.js needs NODE_USE_ENV_PROXY-1 for global env var (https://nodejs.org/api/http.html#http_built_in_proxy_support)
There was a problem hiding this comment.
Added the important callout about environment variables at the top of the proxy support section in 94bc5c6. The note now mentions that Node.js requires NODE_USE_ENV_PROXY=1 to enable built-in proxy support, with a link to the Node.js documentation.
Co-authored-by: pi0 <5158436+pi0@users.noreply.github.com>
Co-authored-by: pi0 <5158436+pi0@users.noreply.github.com>
|
Just as a heads up, I was blocked by some firewall rules while working on your feedback. Expand below for details. Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
…tion Co-authored-by: pi0 <5158436+pi0@users.noreply.github.com>
ofetch works on Node.js, Bun, and Deno, but only Node.js proxy configuration was documented. This PR adds concise proxy documentation for all three runtimes.
Changes
README.md
HTTP_PROXYandHTTPS_PROXYenvironment variablesNODE_USE_ENV_PROXY=1to enable built-in proxy supportProxyAgentwithdispatcheroption (basic proxy, global proxy, self-signed certs)proxyoption:proxy: "http://localhost:3128"examples/proxy.mjs
ofetchcall with all three proxy options shown with clear commentsExample
The unified example in
examples/proxy.mjs:The documentation is compact (~45 lines in README vs original ~130 lines) and the example is unified (~18 lines vs original ~65 lines) while maintaining all essential information.
Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.