I'm a JS Subject Matter Expert (SME) that has spent the past few years spearheading curricula and teaching initiatives at colleges and bootcamps, in person and virtually.
async-await - but sometimes it just makes sense to use a then with a traditional Promise.
We should remember that async is nothing but a 'wrapper' or syntacic sugar for a Promise - it's not wholly different thing. async just makes our code a bit easier to read as it 'looks' 👀 synchronous. And, no callback is needed, mostly. 👍🏾 Callbacks are generally just for 'event based' UI stuff, such as addEventListener.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
async-await- but sometimes it just makes sense to use athenwith a traditionalPromise.We should remember that
asyncis nothing but a 'wrapper' or syntacic sugar for aPromise- it's not wholly different thing.asyncjust makes our code a bit easier to read as it 'looks' 👀 synchronous. And, no callback is needed, mostly. 👍🏾Callbacksare generally just for 'event based' UI stuff, such asaddEventListener.