1 # ansi-styles [![Build Status](https://travis-ci.org/chalk/ansi-styles.svg?branch=master)](https://travis-ci.org/chalk/ansi-styles)
3 > [ANSI escape codes](http://en.wikipedia.org/wiki/ANSI_escape_code#Colors_and_Styles) for styling strings in the terminal
5 You probably want the higher-level [chalk](https://github.com/chalk/chalk) module for styling your strings.
13 $ npm install --save ansi-styles
20 var ansi = require('ansi-styles');
22 console.log(ansi.green.open + 'Hello world!' + ansi.green.close);
28 Each style has an `open` and `close` property.
38 - `italic` *(not widely supported)*
42 - `strikethrough` *(not widely supported)*
70 By default you get a map of styles, but the styles are also available as groups. They are non-enumerable so they don't show up unless you access them explicitly. This makes it easier to expose only a subset in a higher-level module.
80 console.log(ansi.colors.green.open);
86 MIT © [Sindre Sorhus](http://sindresorhus.com)