ansicolor
ansicolor copied to clipboard
A JavaScript ANSI color/style management. ANSI parsing. ANSI to CSS. Small, clean, no dependencies.
https://github.com/xpl/ansicolor/blob/master/build/ansicolor.mjs#L12 because `nice` is just a getter, it gets triggered here :/
for example, ```ts import log from 'ansicolor' //... console.log(log.green('Firefox testing')) ``` on firefox outputs: ` �[32mFirefox testing�[39m` chrome is as expected: 
24-bit color RGB escape sequences are also sometimes referred to as "TrueColor" Example use case: Sometimes logfiles use 24bit RGB color escape sequences to make it easy to identify different...
It seems that a nested color affects a sibling color when a color is applied to both strings up a level. ``` ('aaa' + 'bbb'.magenta).red ``` leads to `aaa` in...
 ``` Could not find a declaration file for module 'ansicolor'. '/workspaces/meta-repo/repos/futarchy-indexer/node_modules/.pnpm/[email protected]/node_modules/ansicolor/build/ansicolor.mjs' implicitly has an 'any' type. There are types at '/workspaces/meta-repo/repos/futarchy-indexer/packages/indexer/node_modules/ansicolor/ansicolor.d.ts', but this result could not be resolved when...
```ts import ansi from 'ansicolor' ansi.rgb = { black: [25, 30, 43], darkGray: [25, 30, 43], lightGray: [104, 104, 104], white: [199, 199, 199], red: [237, 130, 116], lightRed: [242,...