Coder Social home page Coder Social logo

bradparks / hit-that__image_of_website_in_cli_terminal_node_cli Goto Github PK

View Code? Open in Web Editor NEW

This project forked from bevacqua/hit-that

0.0 2.0 0.0 431 KB

:fist: Render beautiful pixel perfect representations of websites in your terminal

Home Page: http://ponyfoo.com

License: MIT License

JavaScript 100.00%

hit-that__image_of_website_in_cli_terminal_node_cli's Introduction

hit-that

Render beautiful pixel perfect representations of websites in your terminal

Installation

npm install -g hit-that

API

Hit That comes with a simple API where it exports just a function hitThat(url, options?). The first argument is the url you intend to render. The second argument is an optional configuration object.

  • width=1024 is the viewport width in pixels that we'll use for the screenshot
  • height=768 is the viewport height in pixels that we'll use for the screenshot
  • cols=80 is the amount of columns we'll allocate to the terminal representation
  • dest=process.stdout is the destination stream you want to pipe the results to.
var hitThat = require('hit-that');

hitThat('http://ponyfoo.com');

CLI

There's a command-line interface as well.

ht ponyfoo.com
Usage:

ht <url> --width [width] --height [height] --cols [cols]

Options:

  --width   Viewport width in pixels
  --height  Viewport height in pixels
  --cols    Terminal columns to use
  --help    Render this information
  --version Render version information

Example

Pony Foo rendered as an image in terminal

Use it as a CLI banner!

Google.com banner

You'll get the best results when reducing the viewport width

Reduced viewport width at emberjs.com

(That site better be responsive!)

License

MIT

hit-that__image_of_website_in_cli_terminal_node_cli's People

Contributors

bevacqua avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.