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

jetty

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jetty

TTY, you so fly

  • 0.2.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
114
increased by18.75%
Maintainers
1
Weekly downloads
 
Created
Source

Jetty

TTY, you so fly.

Overview

Jetty gives you a nice interface to working with ANSI control sequences. If you need a full-blown terminal UI toolkit, you probably want something like curses.

Installation

Available via npm:

$ npm install jetty

Or via git:

$ git clone git://github.com/fknsrs/jetty.git
$ cd jetty
$ npm install

Usage

// Yeah, Jetty!
var Jetty = require("jetty");

// Create a new Jetty object. This is a through stream with some additional
// methods on it. Additionally, connect it to process.stdout
var jetty = new Jetty(process.stdout);

// Clear the screen
jetty.clear();

// Draw a circle with fly colours
var i = 0;
setInterval(function() {
  i += 0.025;

  var x = Math.round(Math.cos(i) * 25 + 50),
      y = Math.round(Math.sin(i) * 13 + 20);

  jetty.rgb(
    Math.round(Math.random() * 215),
    Math.random() > 0.5
  ).moveTo([y,x]).text(".");
}, 5);

License

3-clause BSD. A copy is included with the source.

Contact

Keywords

FAQs

Package last updated on 06 Apr 2013

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