Every JavaScript developer has written this at least once: let resolve , reject ; const promise = new Promise (( res , rej ) => { resolve = res ; reject = rej ; }); // Later… eventBus . on ( ' done ' , () => resolve ( result )); You need to trigger the Promise from outside the constructor — from...

Source: [Dev.to](https://dev.to/parsajiravand/you-keep-escaping-the-promise-constructor-promisewithresolvers-does-it-right-31c1)

Sponsored