Socket
Socket
Sign inDemoInstall

smokestack

Package Overview
Dependencies
217
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    smokestack

Pipe your JavaScript into a browser, logging console output in Node


Version published
Weekly downloads
251
increased by2.87%
Maintainers
1
Install size
691 kB
Created
Weekly downloads
 

Readme

Source

smokestack experimental

Pipe your JavaScript into a browser, logging console output in Node.

Designed for running UI tests on your desktop machine. You can use this, for example, to run tape in the browser and get TAP output in your terminal.

Specifically, it does it like so:

  • Get the JavaScript input through a stream.
  • Instrument the script to pass console calls back home.
  • Host a temporary server with that script.
  • Run a standalone/untainted instance of Chrome and point it to the server.
  • When window.close is called, exit the Chrome process and end the stream.

WORK IN PROGRESS. TODO:

  • CLI interface
  • Support:
    • Firefox
    • Phantom
  • Instead of calling console commands directly, spit it out on the other side of the stream so it can be piped elsewhere. Will require emulation for time, timeEnd, etc.
  • Separate stdout and stderr streams?
  • Support for console methods not available in node.

Module Usage

NPM

stream = smokestack(opts)

Current options:

  • port: the port to run your temporary server on.

License

MIT. See LICENSE.md for details.

Keywords

FAQs

Last updated on 08 Oct 2014

Did you know?

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc