What are the pros and cons of using promises instead of callbacks?
Here are the pros of using promises over callbacks:
- Better defined and organized control flow of asynchronous logic.
- Highly reduced coupling.
- We have integrated error handling.
- Enhanced readability.
Cons of using Promises over callbacks:
- It kills the purpose of asynchronous non-blocking I/O.
- Only one object can be returned.
- We cannot return multiple arguments.
Suggest An Answer
No suggestions Available!