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

Docs: Give tip on why to use sync methods over async #22

Open
mhulse opened this issue Jan 10, 2019 · 2 comments
Open

Docs: Give tip on why to use sync methods over async #22

mhulse opened this issue Jan 10, 2019 · 2 comments

Comments

@mhulse
Copy link
Owner

mhulse commented Jan 10, 2019

Was discussing with coworker and I said this:

I highly recommend dicking around with node CLI stuff ... It's got less stuff to worry about as it's a CLI thing... The trick is to use sync methods as it's easier to manage the code

Typically for cli apps you don't want async

@mhulse
Copy link
Owner Author

mhulse commented Jan 10, 2019

Some other semi-related thoughts about this project:

I think this is a cool example of using node for CLI app:
https://github.com/mhulse/kludgy
if you look at code
I do some cool tricks to use shell scripts and web page scraping ...
That code is currently broken as I think Google maps change something on their API:
mhulse/kludgy#31
But I had a ton of fun writing that. Humble bragging aside, CLI node apps are fun because you don't have to do a bunch of web-related work, and you can hone ES6 node/JS skills for a small but useful project.
For example, on Bitbucket private repos, I have done a ton of CLI apps to help me build printed books ... The key is obviously, having a tool you need to build.
I love shell scripting and bash, but you can do all of that much easier in JS and installing node isn't so bad in terms of a system-level dependency.

@mhulse
Copy link
Owner Author

mhulse commented Feb 13, 2019

Or, use async/await, which is so much easier and non-blocking!

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

1 participant