Add unstable checks for unix transport (#5818)

Also remove the unix example from the stable documentation
to stay in line with the `Deno.listen` one
This commit is contained in:
Valentin Anger 2020-05-24 15:43:40 +02:00 committed by GitHub
parent f6e3160356
commit b7f0b073bb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 3 deletions

View file

@ -1612,10 +1612,9 @@ declare namespace Deno {
* const conn2 = await Deno.connect({ hostname: "192.0.2.1", port: 80 });
* const conn3 = await Deno.connect({ hostname: "[2001:db8::1]", port: 80 });
* const conn4 = await Deno.connect({ hostname: "golang.org", port: 80, transport: "tcp" });
* const conn5 = await Deno.connect({ path: "/foo/bar.sock", transport: "unix" });
* ```
*
* Requires `allow-net` permission for "tcp" and `allow-read` for unix. */
* Requires `allow-net` permission for "tcp". */
export function connect(options: ConnectOptions): Promise<Conn>;
export interface ConnectTlsOptions {