antfu / vscode-iconify

🙂 Iconify IntelliSense for VS Code
https://marketplace.visualstudio.com/items?itemName=antfu.iconify
MIT License
464 stars 34 forks source link

can add proxy config? #7

Closed lanseria closed 2 years ago

lanseria commented 3 years ago
[ant-design] Downloading from https://raw.githubusercontent.com/iconify/collections-json/master/json//ant-design.json
🐛 ERROR: Error: getaddrinfo ENOENT raw.githubusercontent.com
Error: getaddrinfo ENOENT raw.githubusercontent.com
    at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:66:26)
antfu commented 3 years ago

Guess maybe it's better to use a global proxy or whitelist your VS Code.

wuyiw commented 3 years ago

FYI: it seems that axios(use by vscode-iconify) can't get https content via http proxy: axios/axios#658 and to make it work with socks5 proxy some extra work is needed: axios/axios#636.

mseele commented 2 years ago

After having proxy issues, I've investigated a little bit: Seems that axios uses the http_proxy / https_proxy env variables (https://github.com/axios/axios/pull/366) but, like @wuyiw mentioned, it is not possible to get https content via a http proxy (https://github.com/axios/axios/issues/658) which is quite common in bigger networks. I can't believe that there is no js http client out there that makes things right!?! If somebody knows of a js http client library that handles proxies correct, i would love to create a pr to make the plugin work for all people behind proxies.