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

content: add promises example to accepting input from the command line #7252

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

heybosi
Copy link

@heybosi heybosi commented Nov 20, 2024

Description

Validation

Related Issues

Check List

  • I have read the Contributing Guidelines and made commit messages that follow the guideline.
  • I have run npm run format to ensure the code follows the style guide.
  • I have run npm run test to check if all tests are passing.
  • I have run npx turbo build to check if the website builds without errors.
  • I've covered new added functionality with unit tests if necessary.

Signed-off-by: Benson Isaac  <159860495+heybosi@users.noreply.github.com>
@heybosi heybosi requested a review from a team as a code owner November 20, 2024 11:25
Copy link

vercel bot commented Nov 20, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
nodejs-org ✅ Ready (Inspect) Visit Preview Nov 20, 2024 11:26am

Copy link
Member

@avivkeller avivkeller left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have a few concerns:

  1. There is no indication that this is experimental
  2. This isn't formatted (I.e. spacing and capitalization)

I think, you can use code tabs to make this look cleaner

@avivkeller avivkeller changed the title Update accept-input-from-the-command-line-in-nodejs.md to use a promise content: add promises example to accepting input from the command line Nov 20, 2024
Comment on lines +50 to +53
rl.close()

console.log(`Hi ${name}!`);

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
rl.close()
console.log(`Hi ${name}!`);
console.log(`Hi ${name}!`);
rl.close()

Comment on lines +40 to +41
or you could use a promise
```mjs
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
or you could use a promise
```mjs
```mjs displayName="Promises API"

And change the other one accordingly

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

Successfully merging this pull request may close these issues.

2 participants