You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Sep 26, 2019. It is now read-only.
async function detect() { }
const r = detect();
const nativeThen = r.proto.then;
r.proto.then = function () {
console.log('promise.then');
return nativeThen.apply(this, arguments);
}
async function test1() {
console.log('before await');
const r = await test();
console.log('after await');
}
test1();
console.log('end');
// the output will be
// before await
// end
// promise.then, question is why promise.then is after end?
// after await
The nativePromise.then will be executed after end, I don't understand why, any help will be appreciated.
And What is the current status of zone proposal? Thanks!
The text was updated successfully, but these errors were encountered:
The following code
async function detect() { }
const r = detect();
const nativeThen = r.proto.then;
r.proto.then = function () {
console.log('promise.then');
return nativeThen.apply(this, arguments);
}
async function test1() {
console.log('before await');
const r = await test();
console.log('after await');
}
test1();
console.log('end');
// the output will be
// before await
// end
// promise.then, question is why promise.then is after end?
// after await
The nativePromise.then will be executed after end, I don't understand why, any help will be appreciated.
And What is the current status of
zone proposal
? Thanks!The text was updated successfully, but these errors were encountered: