node-http2-proxy icon indicating copy to clipboard operation
node-http2-proxy copied to clipboard

fix(index.d.ts): make `port` option optional

Open dev-itsheng opened this issue 2 years ago • 0 comments

In HTTP request, if the port is default (http -> 80, https -> 443), the port of url can be optional.

And in the source code, it also handles scenarios where port is undefined (or not defined).

So I think in this scene the config of port shouldn't be written, and I omit the port property in my own project and it works fine (with the TypeScript error of course).

I changed the definition of package and make it optional.

dev-itsheng avatar Aug 23 '22 13:08 dev-itsheng