polyhack / nodejsau

11 stars 32 forks source link

Post: Using the 'async' library with Node.js #13

Open amithn opened 11 years ago

amithn commented 11 years ago

My talk on the 31st of June at the Melbourne Node.js meetup covered the async library. Slides from the talk can be found here: http://slid.es/voicestreams/async and my code examples are here: https://github.com/amithn/async-examples

My presentation and code examples explain how to avoid deep nesting of function calls generally referred to as "callback hell" when working with Node.js. Node newbies often run into "callback hell" when they try to build something non-trivial. I have experienced these problems myself and started looking for ways around it. I found that async provides a neat API to overcome the problem.

rvagg commented 11 years ago

Thanks @amithn, would you mind tweaking this a little to be more post-like?

See https://github.com/polyhack/nodejsau/issues/9 and https://github.com/polyhack/nodejsau/issues/10 for examples from the Sydney meetup.

You don't have to go to too much effort, just enough to make it worth putting up on nodejs.org.au. Once you're done we'll make it go live and publicise it on twitter with nodejsau.

sidorares commented 11 years ago

@amithn (or me) - could you make copy of this post - http://www.meetup.com/MelbNodeJS/messages/boards/thread/36746042 ? (need to convert to markdown and add links to presenters github accounts)

amithn commented 11 years ago

The slides and code examples linked from this post explain how to avoid deep nesting of function calls generally referred to as "callback hell" when working with node.js. Node newbies often run into "callback hell" when they try to build something non-trivial. I have experienced these problems myself and started looking for ways around it. I found this library called async @ https://github.com/caolan/async which provides a neat API to overcome the problem.

Below are the link to the slides on how to use the async library as well as introduction with code examples on how to use the different functions provided by async presented at node.js Melbourne meetup on 31st July, 2013.

The slides are here http://slid.es/voicestreams/async and the code examples https://github.com/amithn/async-examples

@rvagg Is this good enough?

rvagg commented 11 years ago

@amithn I've updated your original text with (mostly) your new text and it's gone live at http://nodejs.org.au/ feel free to edit it if you want to modify the wording.

Thanks!

amithn commented 11 years ago

Reads better after your edit. Thank you @rvagg.