-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Labels
13주차13주차13주차
Description
Q2. HTTP 요청 메서드들과 그 목적을 설명해주세요
Q3. 다음 코드의 try catch 구문이 에러를 잡지 못하는 이유는?
try {
setTimeout(() => {
throw new Error('에러 발생!');
}, 1000);
} catch (e) {
console.error('캐치한 에러:', e);
}Q4. Promise 객체는 비동기 작업의 상태와 결과를 내부적으로 어떻게 저장하고 관리하나요?
Q5. Promise의 후속 처리 메서드들이 연속적으로 호출될 수 있는 구조를 설명하는 용어는?
Q6. Promise.resoleve 메서드를 사용하지 않고 동일한 기능을 수행하게 수정해보세요
const resolvedPromise = Promise.reolve(['수정', '진혁', '건휘', '규홍']);
resolvedPromise.then(console.log); // Q7. 실행 결과와 이유를 설명해주세요
setTimeout(() => console.log(1), 0);
Promise.resolve()
.then(() => console.log(2))
.then(() => console.log(3));