Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@nxmix/tokenize-ansi

Package Overview
Dependencies
Maintainers
3
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@nxmix/tokenize-ansi

tokenize a string that includes ansi code

  • 3.0.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
3
Created
Source

tokenize-ansi

styled with prettier Build Status Coverage Status npm Greenkeeper badge

tokenize a string that includes ansi code.

Usage

install

npm install @nxmix/tokenize-ansi

example

import tokenize from '@nxmix/tokenize-ansi'

tokenize("\x1b1A");
// => [ ["up", 1] ], cursor moves up one line

tokenize("\x1b31m" + "a");
// => [ ["red"], ["text", "a"] ], red text

tokenize("\x1b38;2;123,45,67m" + "a");
// => [ ["moreColor", 2, 123, 45, 67], ["text", "a"] ], true-color text

tokenize("\x1b25h");
// => [ ["cursor-on"] ], show cursor

This project follows the all-contributors specification. Contributions of any kind are welcome!

Keywords

FAQs

Package last updated on 14 Jun 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc