Takes an open ANSI code and an input string and adds the open and close
ANSI codes to that string (for text color).
Example
foregroundColor(13)("Vangware"); // "\x1b[13mVangware\x1b[39m" // It can also be used as a tag function for tagged templates: foregroundColor(13)`Vangware`; // "\x1b[13mVangware\x1b[39m"
Returns
Curried function with close ANSI code for text color in context.
Takes an
open
ANSI code and aninput
string and adds the open and close ANSI codes to that string (for text color).Example
Returns
Curried function with
close
ANSI code for text color in context.