Skip to content

Commit 46b6f89

Browse files
committed
change normal comments on ServerOptions to jsdoc comments
1 parent 2df834c commit 46b6f89

File tree

1 file changed

+25
-25
lines changed

1 file changed

+25
-25
lines changed

lib/http-proxy/index.ts

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -32,55 +32,55 @@ export interface ServerOptions {
3232
// actually proxying is called. However, they can be missing when creating the
3333
// proxy server in the first place! E.g., you could make a proxy server P with
3434
// no options, then use P.web(req,res, {target:...}).
35-
// URL string to be parsed with the url module.
35+
/** URL string to be parsed with the url module. */
3636
target?: ProxyTarget;
37-
// URL string to be parsed with the url module or a URL object.
37+
/** URL string to be parsed with the url module or a URL object. */
3838
forward?: ProxyTargetUrl;
39-
// Object to be passed to http(s).request.
39+
/** Object to be passed to http(s).request. */
4040
agent?: any;
41-
// Object to be passed to https.createServer().
41+
/** Object to be passed to https.createServer(). */
4242
ssl?: any;
43-
// If you want to proxy websockets.
43+
/** If you want to proxy websockets. */
4444
ws?: boolean;
45-
// Adds x- forward headers.
45+
/** Adds x- forward headers. */
4646
xfwd?: boolean;
47-
// Verify SSL certificate.
47+
/** Verify SSL certificate. */
4848
secure?: boolean;
49-
// Explicitly specify if we are proxying to another proxy.
49+
/** Explicitly specify if we are proxying to another proxy. */
5050
toProxy?: boolean;
51-
// Specify whether you want to prepend the target's path to the proxy path.
51+
/** Specify whether you want to prepend the target's path to the proxy path. */
5252
prependPath?: boolean;
53-
// Specify whether you want to ignore the proxy path of the incoming request.
53+
/** Specify whether you want to ignore the proxy path of the incoming request. */
5454
ignorePath?: boolean;
55-
// Local interface string to bind for outgoing connections.
55+
/** Local interface string to bind for outgoing connections. */
5656
localAddress?: string;
57-
// Changes the origin of the host header to the target URL.
57+
/** Changes the origin of the host header to the target URL. */
5858
changeOrigin?: boolean;
59-
// specify whether you want to keep letter case of response header key
59+
/** specify whether you want to keep letter case of response header key */
6060
preserveHeaderKeyCase?: boolean;
61-
// Basic authentication i.e. 'user:password' to compute an Authorization header.
61+
/** Basic authentication i.e. 'user:password' to compute an Authorization header. */
6262
auth?: string;
63-
// Rewrites the location hostname on (301 / 302 / 307 / 308) redirects, Default: null.
63+
/** Rewrites the location hostname on (301 / 302 / 307 / 308) redirects, Default: null. */
6464
hostRewrite?: string;
65-
// Rewrites the location host/ port on (301 / 302 / 307 / 308) redirects based on requested host/ port.Default: false.
65+
/** Rewrites the location host/ port on (301 / 302 / 307 / 308) redirects based on requested host/ port.Default: false. */
6666
autoRewrite?: boolean;
67-
// Rewrites the location protocol on (301 / 302 / 307 / 308) redirects to 'http' or 'https'.Default: null.
67+
/** Rewrites the location protocol on (301 / 302 / 307 / 308) redirects to 'http' or 'https'.Default: null. */
6868
protocolRewrite?: string;
69-
// rewrites domain of set-cookie headers.
69+
/** rewrites domain of set-cookie headers. */
7070
cookieDomainRewrite?: false | string | { [oldDomain: string]: string };
71-
// rewrites path of set-cookie headers. Default: false
71+
/** rewrites path of set-cookie headers. Default: false */
7272
cookiePathRewrite?: false | string | { [oldPath: string]: string };
73-
// object with extra headers to be added to target requests.
73+
/** object with extra headers to be added to target requests. */
7474
headers?: { [header: string]: string | string[] | undefined };
75-
// Timeout (in milliseconds) when proxy receives no response from target. Default: 120000 (2 minutes)
75+
/** Timeout (in milliseconds) when proxy receives no response from target. Default: 120000 (2 minutes) */
7676
proxyTimeout?: number;
77-
// Timeout (in milliseconds) for incoming requests
77+
/** Timeout (in milliseconds) for incoming requests */
7878
timeout?: number;
79-
// Specify whether you want to follow redirects. Default: false
79+
/** Specify whether you want to follow redirects. Default: false */
8080
followRedirects?: boolean;
81-
// If set to true, none of the webOutgoing passes are called and it's your responsibility to appropriately return the response by listening and acting on the proxyRes event
81+
/** If set to true, none of the webOutgoing passes are called and it's your responsibility to appropriately return the response by listening and acting on the proxyRes event */
8282
selfHandleResponse?: boolean;
83-
// Buffer
83+
/** Buffer */
8484
buffer?: Stream;
8585
}
8686

0 commit comments

Comments
 (0)