Event-loop: Microtasks vs. Macrotasks
https://developer.mozilla.org/en-US/docs/Web/API/HTML_DOM_API/Microtask_guide/In_depth
In depth: Microtasks and the JavaScript runtime environment - Web APIs | MDN
When debugging or, possibly, when trying to decide upon the best approach to solving a problem around timing and scheduling of tasks and microtasks, there are things about how the JavaScript runtime operates under the hood that may be useful to understand.
developer.mozilla.org
https://javascript.info/event-loop
Event loop: microtasks and macrotasks
javascript.info
Immediately after every macrotask, the engine executes all tasks from microtask queue, prior to running any other macrotasks or rendering or anything else.
https://html.spec.whatwg.org/multipage/webappapis.html#event-loop-processing-model
HTML Standard
html.spec.whatwg.org
https://html.spec.whatwg.org/multipage/webappapis.html#event-loop
HTML Standard
html.spec.whatwg.org
An event loop has one or more task queues. A task queue is a set of tasks.
Task queues are sets, not queues, because step one of the event loop processing model grabs the first runnable task from the chosen queue, instead of dequeuing the first task.
-> Task queue는 자료구조 queue가 아니라 set!
macro-micro 보니까 DSLR 카메라 렌즈가 생각난다. (음?)