Big update!Introducing GitHub Bot Commands. Learn more
Socket
Log inDemoInstall

get-stdin

Package Overview
Dependencies
0
Maintainers
1
Versions
14
Issues
File Explorer

Advanced tools

get-stdin

Get stdin as a string or buffer

    9.0.0latest
    Github

Version published
Maintainers
1
Weekly downloads
18,769,304
increased by7.7%

Weekly downloads

Readme

Source

get-stdin

Get stdin as a string or buffer

Install

$ npm install get-stdin

Usage

// example.js import getStdin from 'get-stdin'; console.log(await getStdin()); //=> 'unicorns' $ echo unicorns | node example.js unicorns

API

Both methods returns a promise that is resolved when the end event fires on the stdin stream, indicating that there is no more data to be read.

getStdin()

Get stdin as a string.

In a TTY context, a promise that resolves to an empty string is returned.

getStdin.buffer()

Get stdin as a Buffer.

In a TTY context, a promise that resolves to an empty Buffer is returned.

  • get-stream - Get a stream as a string or buffer

Get professional support for this package with a Tidelift subscription
Tidelift helps make open source sustainable for maintainers while giving companies
assurances about security, maintenance, and licensing for their dependencies.

Keywords

FAQs

What is get-stdin?

Get stdin as a string or buffer

Is get-stdin popular?

The npm package get-stdin receives a total of 18,047,929 weekly downloads. As such, get-stdin popularity was classified as popular.

Is get-stdin well maintained?

We found that get-stdin demonstrated a not healthy version release cadence and project activity because the last version was released a year ago.It has 1 open source maintainer collaborating on the project.

Last updated on 16 Apr 2021

Did you know?

Socket installs a Github app to automatically flag issues on every pull request and report the health of your dependencies. Find out what is inside your node modules and prevent malicious activity before you update the dependencies.

Install Socket
Socket[email protected]

Product

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc