$ Toast

static output4 types

Styled notification messages for terminal output with 4 preset types: success, error, warning, and info. Supports timestamps.

# Preview

toast demo
──────────────────────────────────────
✔ SUCCESS
Build completed successfully!
──────────────────────────────────────
──────────────────────────────────────
✖ ERROR
Connection refused on port 5432
──────────────────────────────────────
──────────────────────────────────────
⚠ WARNING
Deprecated API: use v2 endpoint
──────────────────────────────────────
──────────────────────────────────────
ℹ INFO
Server listening on port 3000
──────────────────────────────────────

# Usage

example.ts
import { toast, Toast } from "@vr_patel/tui";

// Quick one-liners
console.log(toast.success("Build completed!"));
console.log(toast.error("Connection failed"));
console.log(toast.warn("Deprecated API"));
console.log(toast.info("Server running on port 3000"));

// With options
const t = new Toast({ timestamp: true });
console.log(t.success("Deployed to production"));

# API

PropTypeDefaultDescription
widthnumber0 (auto)Fixed width or auto-sized
paddingnumber1Padding inside the toast
timestampbooleanfalseShow timestamp in header