TooTallNate / proxy-agents

Node.js HTTP Proxy Agents Monorepo
https://proxy-agents.n8.io
872 stars 229 forks source link

TypeError: Class extends value undefined is not a constructor or null #223

Closed ByFishh closed 11 months ago

ByFishh commented 11 months ago

Hi, when I use this simple code with the latest version of http-proxy-agent I got this error. I'm using React + typescript with Vite.

import { HttpProxyAgent } from 'http-proxy-agent';

const agent = new HttpProxyAgent('http://168.63.76.32:31

image

TooTallNate commented 11 months ago

So this is code that is running on the browser?

albertpratomo commented 8 months ago
image

Hi, I also get the same error. Is this package not supposed to be used in browser?

frama21 commented 7 months ago

yeah same like @albertpratomo issue, cc : @TooTallNate

TooTallNate commented 7 months ago

Correct, this package is meant to be used in Node.js code, not in the browser.