BREAKING(net/unstable): move get-network-address module to unstable-get-network-address (#5949)

* BREAKING(net/unstable): move `get-network-address` module to `unstable-get-network-address`

* fix

* fix
This commit is contained in:
Asher Gomez 2024-09-12 14:05:40 +10:00 committed by GitHub
parent b76ae272ae
commit b900e72b3d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 7 additions and 9 deletions

View File

@ -66,6 +66,7 @@ const ENTRY_POINTS = [
"../media_types/mod.ts",
"../msgpack/mod.ts",
"../net/mod.ts",
"../net/unstable_get_network_address.ts",
"../path/mod.ts",
"../path/posix/mod.ts",
"../path/windows/mod.ts",

View File

@ -51,7 +51,7 @@ import { ByteSliceStream } from "@std/streams/byte-slice-stream";
import { parseArgs } from "@std/cli/parse-args";
import denoConfig from "./deno.json" with { type: "json" };
import { format as formatBytes } from "@std/fmt/bytes";
import { getNetworkAddress } from "@std/net/get-network-address";
import { getNetworkAddress } from "@std/net/unstable-get-network-address";
import { HEADER } from "./unstable_header.ts";
import { METHOD } from "./unstable_method.ts";

View File

@ -4,6 +4,6 @@
"exports": {
".": "./mod.ts",
"./get-available-port": "./get_available_port.ts",
"./get-network-address": "./get_network_address.ts"
"./unstable-get-network-address": "./unstable_get_network_address.ts"
}
}

View File

@ -4,9 +4,7 @@
* Network utilities.
*
* ```ts no-assert no-eval
* import { getNetworkAddress, getAvailablePort } from "@std/net";
*
* console.log(`My network IP address is ${getNetworkAddress()}`);
* import { getAvailablePort } from "@std/net";
*
* const command = new Deno.Command(Deno.execPath(), {
* args: ["test.ts", "--port", getAvailablePort().toString()],
@ -19,4 +17,3 @@
*/
export * from "./get_available_port.ts";
export * from "./get_network_address.ts";

View File

@ -17,7 +17,7 @@
*
* @example Get the IPv4 network address (default)
* ```ts no-assert no-eval
* import { getNetworkAddress } from "@std/net/get-network-address";
* import { getNetworkAddress } from "@std/net/unstable-get-network-address";
*
* const hostname = getNetworkAddress()!;
*
@ -26,7 +26,7 @@
*
* @example Get the IPv6 network address
* ```ts no-assert no-eval
* import { getNetworkAddress } from "@std/net/get-network-address";
* import { getNetworkAddress } from "@std/net/unstable-get-network-address";
*
* const hostname = getNetworkAddress("IPv6")!;
*

View File

@ -1,5 +1,5 @@
// Copyright 2018-2024 the Deno authors. All rights reserved. MIT license.
import { getNetworkAddress } from "./get_network_address.ts";
import { getNetworkAddress } from "./unstable_get_network_address.ts";
import { stub } from "@std/testing/mock";
import { assertEquals } from "@std/assert";