https://github.com/caolan/async
https://github.com/maxtaco/tamejs
These are two modules. To me, it seems like the same thing, right?
Or…are they used in different situations?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
asyncis a library that provides methods to let you control the flow of your program. For example: “I want to process each item in the array asynchronously and have this function executed after all processing is completed”.TameJS makes you write code that isn’t JS, but will get converted to JS. It’s aim is to make the way to do asynchronous programming more easy to follow.
I personally used TameJS, and there are a few problems with it:
return res.send(200)where the request was not being sent. It has been fixed by now, but it put a very bad taste in my mouth.I am now using
asyncand find it can make the code very easy to read and understand.As a final suggestion, perhaps you should try writing your own code to manage the control flow. If you are new to JS, then that would be a very good learning experience to see what these libraries are doing on the inside. Even if you are in a time crunch, it would be best to understand what external libraries do, so you can make the best use of them.