outter
inner
点我,猜猜console
var out = document.getElementById('outter')
var inner = document.getElementById('inner')
out.addEventListener('click', function(){
console.log('outter')
setTimeout(()=>{
console.log('this is outter settimeout')
})
Promise.resolve(111).then(res =>{
console.log('this is outter promise')
})
})
inner.addEventListener('click', function(){
console.log('inner')
setTimeout(()=>{
console.log('this is inner settimeout')
})
Promise.resolve(111).then(res =>{
console.log('this is inner promise')
})
})