Y
Hacker News
new
|
ask
|
show
|
jobs
by
THBC
668 days ago
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()