Chalk Utilities
Chalk provides chainable text styles, colors, gradients, and effects.
Examples
1import { chalk } from 'hbh-terminal';3// Basic colors & styles4console.log(chalk.red.bold('🔥 Bold Red'));5console.log(chalk.blue.underline('💧 Underlined Blue'));6console.log(chalk.magenta.italic('💖 Italic Magenta'));8// RGB / HEX / HSL9console.log(chalk.rgb(100, 200, 50)('🌿 Custom RGB'));10console.log(chalk.hex('#ff00ff')('💜 HEX Text'));11console.log(chalk.hsl(200, 100, 50)('💧 HSL Text'));13// Rainbow and gradients14console.log(chalk.rainbow('🌈 Rainbow Text'));15console.log(chalk.bgRainbow('🌈 Background Rainbow'));16console.log(chalk.gradientText('Gradient Text', 'red', 'blue'));
Effects
blinking– text blinksrandom– random colors per characterbgColorize– random background per characteralterNateColor– cycle through an array of colorsalterNateBG– cycle through an array of background colors