Tables
$

Table

FREE

Formatted data tables with headers, auto-sized columns, alternating row colors, alignment, and Unicode borders.

static outputautosizeunicode

# Preview

bordered-table demo
BOOTING PREVIEW

# Usage

import { Table, fg, colorize } from '@taracod/termui';

const table = new Table({
  headers: ['Name', 'Role', 'Status'],
  rows: [
    ['Alice', 'Engineer', colorize('Active', fg.green)],
    ['Bob', 'Designer', colorize('Away', fg.yellow)],
    ['Charlie', 'Manager', colorize('Active', fg.green)],
  ],
  alternateRowColor: true,
});

console.log(table.render());

# API

PropTypeDefaultDescription
headersstring[][]Column labels rendered in header row
rowsCell[][]requiredData rows, including colored strings
borderbooleantrueRender Unicode table border
alternateRowColorbooleanfalseApply subtle zebra styling to rows
Support TermUI