What are promises?
- promises are objects in javascript that represents the eventual completion of an asynchronous operation
- a promise has 3 states, fulfilled (resolved), rejected and pending
- evenutally either resolved or rejected
- promises are a way to handle async operations in javascript. they are js object that represents the eventual completion of the async operation. If the async operation succeeds, the promise is said to be resolved, else it is rejected.