mirror of
https://github.com/denoland/deno.git
synced 2025-09-27 12:49:10 +00:00
Add Deno.hostname() (#3032)
This commit is contained in:
parent
d36391ad20
commit
6efca6d1a1
9 changed files with 60 additions and 1 deletions
6
js/lib.deno_runtime.d.ts
vendored
6
js/lib.deno_runtime.d.ts
vendored
|
@ -22,6 +22,12 @@ declare namespace Deno {
|
|||
stdout: boolean;
|
||||
stderr: boolean;
|
||||
};
|
||||
/** Get the hostname.
|
||||
* Requires the `--allow-env` flag.
|
||||
*
|
||||
* console.log(Deno.hostname());
|
||||
*/
|
||||
export function hostname(): string;
|
||||
/** Exit the Deno process with optional exit code. */
|
||||
export function exit(code?: number): never;
|
||||
/** Returns a snapshot of the environment variables at invocation. Mutating a
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue