Kargi-Sitesi/node_modules/has-ansi
2024-11-03 21:30:09 -05:00
..
node_modules/ansi-regex Deployed the page to Github Pages. 2024-11-03 21:30:09 -05:00
index.js Deployed the page to Github Pages. 2024-11-03 21:30:09 -05:00
package.json Deployed the page to Github Pages. 2024-11-03 21:30:09 -05:00
readme.md Deployed the page to Github Pages. 2024-11-03 21:30:09 -05:00

has-ansi Build Status

Check if a string has ANSI escape codes

Install

$ npm install --save has-ansi

Usage

var hasAnsi = require('has-ansi');

hasAnsi('\u001b[4mcake\u001b[0m');
//=> true

hasAnsi('cake');
//=> false

CLI

$ npm install --global has-ansi
$ has-ansi --help

Usage
  $ has-ansi <string>
  $ echo <string> | has-ansi

Exits with code 0 if input has ANSI escape codes and 1 if not

License

MIT © Sindre Sorhus