Skip to content

Link

widgetsdisplay

Whether to append the URL visually when terminal capabilities lack unicode/OSC 8 support

Installation

$ bunx termuijs add link

Copies the source into src/components/link/ and installs @termuijs/core, @termuijs/widgets.

Usage

ts
import { Link } from '@termuijs/widgets'
ts
new Link(text: string, style: Partial<Style> | undefined, opts: LinkOptions)

API Reference

Link

PropTypeRequiredDescription
textstringrequired
urlstringrequiredThe target URL for the OSC 8 hyperlink anchor
colorColoroptionalUnderline and anchor fallback color object
showUrlFallbackbooleanoptionalWhether to append the URL visually when terminal capabilities lack unicode/OSC 8 support
#display#link