import { consoleSizeViaDenoAPI } from "https://deno.land/x/dxx@rf/src/lib/consoleSize.ts";
Get the size of the console used by rid
as columns/rows, using options
, via the Deno API.
- unstable ~ requires the Deno
--unstable
flag for successful resolution (b/c the usedDeno.consoleSize()
function is unstable API [as of Deno v1.19.0, 2022-02-17])
const { columns, rows } = consoleSizeViaDenoAPI(Deno.stdout.rid, {...});
Parameters
optional
options_: Partial<Omit<ConsoleSizeOptions, "useCache">> = [UNSUPPORTED]Returns
ConsoleSize | undefined