Skip to main content
Module

x/crayon/src/crayon.ts

🖍️ Terminal styling done light and fast.
Go to Latest
import * as crayon from "https://deno.land/x/crayon@3.3.2/src/crayon.ts";

Variables

An object that expresses how well terminal supports displaying colors

🖍️ Crayon object that's used for styling

  • Call the last property as a function with arguments to get styled string

Map containing all style functions used by crayon

Object, which gets set as the prototype of every generated crayon instance in generateCrayon() function

Map containing all styles used by crayon

Functions

Uses mapFunc on every given function

  • func.name will be considered as name parameter

Uses mapStyle on every given style code

  • map key will be used as name parameter

Type Aliases

Crayon type which can be easily extended C - literal string type for extending styles O - object which expands