Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

16장 - 자바스크립트 이벤트 루프 #11

Open
sa02045 opened this issue Jul 22, 2023 · 0 comments
Open

16장 - 자바스크립트 이벤트 루프 #11

sa02045 opened this issue Jul 22, 2023 · 0 comments

Comments

@sa02045
Copy link

sa02045 commented Jul 22, 2023

자바스크립트 이벤트 루프 - 큐 에 대해 깊게 알아봅시다.

  • 콘솔 출력 순서는?
  • 큐의 종류는?
setTimeout(() => {
  console.log("setTimeout-1");
});

requestAnimationFrame(() => {
  console.log("requestAnimationFrame-1");
});

console.log("a");

new Promise(() => {
  console.log("Promise-1");
});

queueMicrotask(() => {
  console.log("queueMicrotask-1");
});

setTimeout(() => {
  console.log("setTimeout-2");
}, 0);

new Promise(() => {
  console.log("Promise-2");
});

requestAnimationFrame(() => {
  console.log("requestAnimationFrame-2");
});

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant