News for hackers. Stuff that matters.
Re:I avoid async/await in JavaScript by THBC on Tuesday August 13, 2024 @05:43PM (#41240170)
That’s not ”raw Promise” syntax, that’s Thenable syntax.

Compare with

    const myPromise = new Promise((resolve, reject) => resolve(”foo”));
    
Afterwards either try-catch await myPromise, or use myPromise.then().catch()

There are no comments on this comment yet.