Module

x/cliffy/packages/table/mod.ts>Table

Command line framework for deno 🦕 Including Commandline-Interfaces, Prompts, CLI-Table, Arguments Parser and more...
Extremely Popular
Go to Latest
class Table
extends Array<T>
import { Table } from "https://dotland.deno.dev/x/cliffy@v0.12.0/packages/table/mod.ts";

Type Parameters

optional
T extends IRow = IRow

Properties

private
optional
headerRow: Row
protected
options: ITableSettings

Methods

body(rows: T[]): this
border(enable: boolean, override?: boolean): this
chars(chars: IBorderOptions): this
fromJson(rows: IDataRow[]): this
getBody(): T[]
getBorder(): boolean
getHeader(): Row | undefined
getIndent(): number
getMaxCellWidth(): number | number[]
getMinCellWidth(): number | number[]
getPadding(): number | number[]
hasBodyBorder(): boolean
hasBorder(): boolean
hasHeaderBorder(): boolean
header(header: IRow): this
indent(width: number, override?: boolean): this
maxCellWidth(width: number | number[], override?: boolean): this
minCellWidth(width: number | number[], override?: boolean): this
padding(padding: number | number[], override?: boolean): this
render(): this
toString(): string

Static Methods

from<T extends IRow>(rows: ITable<T>): Table<T>
render<T extends IRow>(rows: ITable<T>): void