Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Marking Repo as Deprecated and Offering Alternatives #58

Open
joshuabremerdexcom opened this issue Mar 1, 2022 · 3 comments
Open

Marking Repo as Deprecated and Offering Alternatives #58

joshuabremerdexcom opened this issue Mar 1, 2022 · 3 comments

Comments

@joshuabremerdexcom
Copy link

This repo has a vulnerability that isn't being addressed. This repo seems abandoned. I wanted to offer an alternative that is working well for me with the readline sync package (https://github.com/anseki/readline-sync#utility_methods-keyinyn):

Before:

const prompt = require('prompt-sync')();
prompt('> ')

After using readline-sync:

const readlineSync = require('readline-sync');
const answer = readlineSync.prompt();
@BenSjoberg
Copy link

Came here looking for an alternative after noticing the npm audit warning. Thanks for sharing!

@phunanon
Copy link

phunanon commented Nov 3, 2023

readline-sync seems now, itself, deprecated.

@dave-kennedy
Copy link

The node:readline module looks like it's easy enough to use by itself:

import * as readline from 'node:readline/promises';
import { stdin as input, stdout as output } from 'node:process';

const rl = readline.createInterface({ input, output });

const answer = await rl.question('What do you think of Node.js? ');

console.log(`Thank you for your valuable feedback: ${answer}`);

rl.close();

See https://nodejs.org/docs/latest-v20.x/api/readline.html.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants