{\bfseries{Contributing}}

\begin{quote}
Easily add ANSI colors to your text and symbols in the terminal. A faster drop-\/in replacement for chalk, kleur and turbocolor (without the dependencies and rendering bugs). \end{quote}
Please consider following this project\textquotesingle{}s author, \href{https://github.com/doowb}{\texttt{ Brian Woodward}}, and consider starring the project to show your \+:heart\+: and support.\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2976}{}\doxysection{Install}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2976}
Install with \href{https://www.npmjs.com/}{\texttt{ npm}}\+:


\begin{DoxyCode}{0}
\DoxyCodeLine{\$ npm install -\/-\/save ansi-\/colors }

\end{DoxyCode}


\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2977}{}\doxysection{Why use this?}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2977}
ansi-\/colors is {\itshape the fastest Node.\+js library for terminal styling}. A more performant drop-\/in replacement for chalk, with no dependencies.


\begin{DoxyItemize}
\item {\itshape Blazing fast} -\/ Fastest terminal styling library in node.\+js, 10-\/20x faster than chalk!
\item {\itshape Drop-\/in replacement} for \href{https://github.com/chalk/chalk}{\texttt{ chalk}}.
\item {\itshape No dependencies} (Chalk has 7 dependencies in its tree!)
\item {\itshape Safe} -\/ Does not modify the {\ttfamily String.\+prototype} like \href{https://github.com/Marak/colors.js}{\texttt{ colors}}.
\item Supports \href{\#nested-colors}{\texttt{ nested colors}}, {\bfseries{and does not have the \href{\#nested-styling-bug}{\texttt{ nested styling bug}} that is present in \href{https://github.com/jorgebucaran/colorette}{\texttt{ colorette}}, \href{https://github.com/chalk/chalk}{\texttt{ chalk}}, and \href{https://github.com/lukeed/kleur}{\texttt{ kleur}}}}.
\item Supports \href{\#chained-colors}{\texttt{ chained colors}}.
\item \href{\#toggle-color-support}{\texttt{ Toggle color support}} on or off.
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2978}{}\doxysection{Usage}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2978}

\begin{DoxyCode}{0}
\DoxyCodeLine{const c = require('ansi-\/colors');}
\DoxyCodeLine{}
\DoxyCodeLine{console.log(c.red('This is a red string!'));}
\DoxyCodeLine{console.log(c.green('This is a red string!'));}
\DoxyCodeLine{console.log(c.cyan('This is a cyan string!'));}
\DoxyCodeLine{console.log(c.yellow('This is a yellow string!')); }

\end{DoxyCode}


\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2979}{}\doxysection{Chained colors}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2979}

\begin{DoxyCode}{0}
\DoxyCodeLine{console.log(c.bold.red('this is a bold red message'));}
\DoxyCodeLine{console.log(c.bold.yellow.italic('this is a bold yellow italicized message'));}
\DoxyCodeLine{console.log(c.green.bold.underline('this is a bold green underlined message')); }

\end{DoxyCode}


\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2980}{}\doxysection{Nested colors}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2980}

\begin{DoxyCode}{0}
\DoxyCodeLine{console.log(c.yellow(`foo \$\{c.red.bold('red')\} bar \$\{c.cyan('cyan')\} baz`)); }

\end{DoxyCode}


\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2981}{}\doxysubsection{Nested styling bug}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2981}
{\ttfamily ansi-\/colors} does not have the nested styling bug found in \href{https://github.com/jorgebucaran/colorette}{\texttt{ colorette}}, \href{https://github.com/chalk/chalk}{\texttt{ chalk}}, and \href{https://github.com/lukeed/kleur}{\texttt{ kleur}}.


\begin{DoxyCode}{0}
\DoxyCodeLine{const \{ bold, red \} = require('ansi-\/styles');}
\DoxyCodeLine{console.log(bold(`foo \$\{red.dim('bar')\} baz`));}
\DoxyCodeLine{}
\DoxyCodeLine{const colorette = require('colorette');}
\DoxyCodeLine{console.log(colorette.bold(`foo \$\{colorette.red(colorette.dim('bar'))\} baz`));}
\DoxyCodeLine{}
\DoxyCodeLine{const kleur = require('kleur');}
\DoxyCodeLine{console.log(kleur.bold(`foo \$\{kleur.red.dim('bar')\} baz`));}
\DoxyCodeLine{}
\DoxyCodeLine{const chalk = require('chalk');}
\DoxyCodeLine{console.log(chalk.bold(`foo \$\{chalk.red.dim('bar')\} baz`)); }

\end{DoxyCode}


{\bfseries{Results in the following}}

(sans icons and labels)

\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2982}{}\doxysection{Toggle color support}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2982}
Easily enable/disable colors.


\begin{DoxyCode}{0}
\DoxyCodeLine{const c = require('ansi-\/colors');}
\DoxyCodeLine{}
\DoxyCodeLine{// disable colors manually}
\DoxyCodeLine{c.enabled = false;}
\DoxyCodeLine{}
\DoxyCodeLine{// or use a library to automatically detect support}
\DoxyCodeLine{c.enabled = require('color-\/support').hasBasic;}
\DoxyCodeLine{}
\DoxyCodeLine{console.log(c.red('I will only be colored red if the terminal supports colors')); }

\end{DoxyCode}
\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2983}{}\doxysection{Strip ANSI codes}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2983}
Use the {\ttfamily .unstyle} method to strip ANSI codes from a string.


\begin{DoxyCode}{0}
\DoxyCodeLine{console.log(c.unstyle(c.blue.bold('foo bar baz')));}
\DoxyCodeLine{//=> 'foo bar baz' }

\end{DoxyCode}
\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2984}{}\doxysection{Available styles}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2984}
{\bfseries{Note}} that bright and bright-\/background colors are not always supported.

\tabulinesep=1mm
\begin{longtabu}spread 0pt [c]{*{4}{|X[-1]}|}
\hline
\PBS\centering \cellcolor{\tableheadbgcolor}\textbf{ Colors   }&\PBS\centering \cellcolor{\tableheadbgcolor}\textbf{ Background Colors   }&\PBS\centering \cellcolor{\tableheadbgcolor}\textbf{ Bright Colors   }&\PBS\centering \cellcolor{\tableheadbgcolor}\textbf{ Bright Background Colors    }\\\cline{1-4}
\endfirsthead
\hline
\endfoot
\hline
\PBS\centering \cellcolor{\tableheadbgcolor}\textbf{ Colors   }&\PBS\centering \cellcolor{\tableheadbgcolor}\textbf{ Background Colors   }&\PBS\centering \cellcolor{\tableheadbgcolor}\textbf{ Bright Colors   }&\PBS\centering \cellcolor{\tableheadbgcolor}\textbf{ Bright Background Colors    }\\\cline{1-4}
\endhead
black   &bg\+Black   &black\+Bright   &bg\+Black\+Bright    \\\cline{1-4}
red   &bg\+Red   &red\+Bright   &bg\+Red\+Bright    \\\cline{1-4}
green   &bg\+Green   &green\+Bright   &bg\+Green\+Bright    \\\cline{1-4}
yellow   &bg\+Yellow   &yellow\+Bright   &bg\+Yellow\+Bright    \\\cline{1-4}
blue   &bg\+Blue   &blue\+Bright   &bg\+Blue\+Bright    \\\cline{1-4}
magenta   &bg\+Magenta   &magenta\+Bright   &bg\+Magenta\+Bright    \\\cline{1-4}
cyan   &bg\+Cyan   &cyan\+Bright   &bg\+Cyan\+Bright    \\\cline{1-4}
white   &bg\+White   &white\+Bright   &bg\+White\+Bright    \\\cline{1-4}
gray   &&&\\\cline{1-4}
grey   &&&\\\cline{1-4}
\end{longtabu}


\+\_\+({\ttfamily gray} is the U.\+S. spelling, {\ttfamily grey} is more commonly used in the Canada and U.\+K.)\+\_\+\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2985}{}\doxysubsection{Style modifiers}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2985}

\begin{DoxyItemize}
\item dim
\item {\bfseries{bold}}
\item hidden
\item {\itshape italic}
\item underline
\item inverse
\item \sout{strikethrough}
\item reset
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2986}{}\doxysection{Performance}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2986}
{\bfseries{Libraries tested}}


\begin{DoxyItemize}
\item ansi-\/colors v3.\+0.\+4
\item chalk v2.\+4.\+1
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2987}{}\doxysubsection{Mac}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2987}
\begin{quote}
Mac\+Book Pro, Intel Core i7, 2.\+3 GHz, 16 GB. \end{quote}
{\bfseries{Load time}}

Time it takes to load the first time {\ttfamily require()} is called\+:


\begin{DoxyItemize}
\item ansi-\/colors -\/ {\ttfamily 1.\+915ms}
\item chalk -\/ {\ttfamily 12.\+437ms}
\end{DoxyItemize}

{\bfseries{Benchmarks}}


\begin{DoxyCode}{0}
\DoxyCodeLine{\# All Colors}
\DoxyCodeLine{  ansi-\/colors x 173,851 ops/sec ±0.42\% (91 runs sampled)}
\DoxyCodeLine{  chalk x 9,944 ops/sec ±2.53\% (81 runs sampled)))}
\DoxyCodeLine{}
\DoxyCodeLine{\# Chained colors}
\DoxyCodeLine{  ansi-\/colors x 20,791 ops/sec ±0.60\% (88 runs sampled)}
\DoxyCodeLine{  chalk x 2,111 ops/sec ±2.34\% (83 runs sampled)}
\DoxyCodeLine{}
\DoxyCodeLine{\# Nested colors}
\DoxyCodeLine{  ansi-\/colors x 59,304 ops/sec ±0.98\% (92 runs sampled)}
\DoxyCodeLine{  chalk x 4,590 ops/sec ±2.08\% (82 runs sampled) }

\end{DoxyCode}
\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2988}{}\doxysubsection{Windows}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2988}
\begin{quote}
Windows 10, Intel Core i7-\/7700k CPU @ 4.\+2 GHz, 32 GB \end{quote}
{\bfseries{Load time}}

Time it takes to load the first time {\ttfamily require()} is called\+:


\begin{DoxyItemize}
\item ansi-\/colors -\/ {\ttfamily 1.\+494ms}
\item chalk -\/ {\ttfamily 11.\+523ms}
\end{DoxyItemize}

{\bfseries{Benchmarks}}


\begin{DoxyCode}{0}
\DoxyCodeLine{\# All Colors}
\DoxyCodeLine{  ansi-\/colors x 193,088 ops/sec ±0.51\% (95 runs sampled))}
\DoxyCodeLine{  chalk x 9,612 ops/sec ±3.31\% (77 runs sampled)))}
\DoxyCodeLine{}
\DoxyCodeLine{\# Chained colors}
\DoxyCodeLine{  ansi-\/colors x 26,093 ops/sec ±1.13\% (94 runs sampled)}
\DoxyCodeLine{  chalk x 2,267 ops/sec ±2.88\% (80 runs sampled))}
\DoxyCodeLine{}
\DoxyCodeLine{\# Nested colors}
\DoxyCodeLine{  ansi-\/colors x 67,747 ops/sec ±0.49\% (93 runs sampled)}
\DoxyCodeLine{  chalk x 4,446 ops/sec ±3.01\% (82 runs sampled)) }

\end{DoxyCode}
\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2989}{}\doxysection{About}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2989}
$<$details$>$

Pull requests and stars are always welcome. For bugs and feature requests, \href{../../issues/new}{\texttt{ please create an issue}}.

$<$/details$>$

$<$details$>$

{\bfseries{Running Tests}} 

Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command\+:


\begin{DoxyCode}{0}
\DoxyCodeLine{\$ npm install \&\& npm test }

\end{DoxyCode}


$<$/details$>$

$<$details$>$

{\bfseries{Building docs}} 

\+\_\+(This project\textquotesingle{}s readme.\+md is generated by \href{https://github.com/verbose/verb-generate-readme}{\texttt{ verb}}, please don\textquotesingle{}t edit the readme directly. Any changes to the readme must be made in the .verb.md readme template.)\+\_\+

To generate the readme, run the following command\+:


\begin{DoxyCode}{0}
\DoxyCodeLine{\$ npm install -\/g verbose/verb\#dev verb-\/generate-\/readme \&\& verb }

\end{DoxyCode}


$<$/details$>$\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2990}{}\doxysubsection{Related projects}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2990}
You might also be interested in these projects\+:


\begin{DoxyItemize}
\item \href{https://www.npmjs.com/package/ansi-wrap}{\texttt{ ansi-\/wrap}}\+: Create ansi colors by passing the open and close codes. $\vert$ \href{https://github.com/jonschlinkert/ansi-wrap}{\texttt{ homepage}}
\item \href{https://www.npmjs.com/package/strip-color}{\texttt{ strip-\/color}}\+: Strip ANSI color codes from a string. No dependencies. $\vert$ \href{https://github.com/jonschlinkert/strip-color}{\texttt{ homepage}}
\end{DoxyItemize}\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2991}{}\doxysubsection{Contributors}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2991}
\tabulinesep=1mm
\begin{longtabu}spread 0pt [c]{*{2}{|X[-1]}|}
\hline
\PBS\centering \cellcolor{\tableheadbgcolor}\textbf{ {\bfseries{Commits}}   }&\PBS\centering \cellcolor{\tableheadbgcolor}\textbf{ {\bfseries{Contributor}}    }\\\cline{1-2}
\endfirsthead
\hline
\endfoot
\hline
\PBS\centering \cellcolor{\tableheadbgcolor}\textbf{ {\bfseries{Commits}}   }&\PBS\centering \cellcolor{\tableheadbgcolor}\textbf{ {\bfseries{Contributor}}    }\\\cline{1-2}
\endhead
42   &\href{https://github.com/doowb}{\texttt{ doowb}}    \\\cline{1-2}
38   &\href{https://github.com/jonschlinkert}{\texttt{ jonschlinkert}}    \\\cline{1-2}
6   &\href{https://github.com/lukeed}{\texttt{ lukeed}}    \\\cline{1-2}
2   &\href{https://github.com/Silic0nS0ldier}{\texttt{ Silic0n\+S0ldier}}    \\\cline{1-2}
1   &\href{https://github.com/dwieeb}{\texttt{ dwieeb}}    \\\cline{1-2}
1   &\href{https://github.com/jorgebucaran}{\texttt{ jorgebucaran}}    \\\cline{1-2}
1   &\href{https://github.com/madhavarshney}{\texttt{ madhavarshney}}    \\\cline{1-2}
1   &\href{https://github.com/chapterjason}{\texttt{ chapterjason}}   \\\cline{1-2}
\end{longtabu}
\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2992}{}\doxysubsection{Author}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2992}
{\bfseries{Brian Woodward}}


\begin{DoxyItemize}
\item \href{https://github.com/doowb}{\texttt{ Git\+Hub Profile}}
\item \href{https://twitter.com/doowb}{\texttt{ Twitter Profile}}
\item \href{https://linkedin.com/in/woodwardbrian}{\texttt{ Linked\+In Profile}}
\end{DoxyItemize}

Please consider supporting me on Patreon, or \href{https://patreon.com/invite/bxpbvm}{\texttt{ start your own Patreon page}}!

\href{https://www.patreon.com/jonschlinkert}{\texttt{  }}\hypertarget{md_sfcode_node_modules_ansi_colors_README_autotoc_md2993}{}\doxysubsection{License}\label{md_sfcode_node_modules_ansi_colors_README_autotoc_md2993}
Copyright © 2019, \href{https://github.com/doowb}{\texttt{ Brian Woodward}}. Released under the \mbox{[}MIT License\mbox{]}(LICENSE).

\DoxyHorRuler{0}


{\itshape This file was generated by \href{https://github.com/verbose/verb-generate-readme}{\texttt{ verb-\/generate-\/readme}}, v0.\+8.\+0, on March 03, 2019.} 