Skip to content

Commit

Permalink
🔥 remove docs folder
Browse files Browse the repository at this point in the history
  • Loading branch information
astoilkov committed Jan 16, 2024
1 parent c8cd0db commit 82ebdf6
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 72 deletions.
72 changes: 0 additions & 72 deletions docs/in-depth-overview.md

This file was deleted.

24 changes: 24 additions & 0 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -141,3 +141,27 @@ async function postTask(callback: () => void | Promise<void>, options?: {
### Web Workers

Web Workers are a great fit if you have: 1) heavy algorithm (e.g. image processing), 2) heavy process (runs for a long time, big part of the app lifecycle). However, in reality, it's rare to see people using them. That's because they require significant investment of time due to the complexity that can't be avoided when working with CPU threads regardless of the programming language. This library can be used as a gateway before transitioning to Web Workers. In most cases, you would discover the doing it on the main thread is good enough.

<!--
## Resources
Documents associated with implementing main thread scheduling in browsers:
- [WICG/main-thread-scheduling](https://github.com/WICG/main-thread-scheduling) and more specifically [Main Thread Scheduling: Prioritized postTask API](https://github.com/WICG/main-thread-scheduling/blob/646edfc3d735333162fb7a447c845b49b6a11d66/PrioritizedPostTask.md)
- [Native Web Scheduling MVP: API Proposal](https://docs.google.com/document/d/1xU7HyNsEsbXhTgt0ZnXDbeSXm5-m5FzkLJAT6LTizEI/edit#)
- [Threading and Tasks in Chrome](https://chromium.googlesource.com/chromium/src/+/refs/tags/62.0.3175.0/docs/threading_and_tasks.md#Posting-a-Parallel-Task)
- [Signal-Based postTask Design](https://docs.google.com/document/d/1Apz-SD-pOagGeyWxIpgOi0ARNkrCrELhPdm18eeu9tw/edit)
Articles that talk about scheduling tasks in the browser:
- [The hidden magic of Main Thread Scheduling](https://medium.com/nmc-techblog/the-hidden-magic-of-main-thread-scheduling-5f20b7803293)
- [Sneak Peek: Beyond React 16 – React Blog](https://reactjs.org/blog/2018/03/01/sneak-peek-beyond-react-16.html)
- [Scheduling in React](https://philippspiess.com/scheduling-in-react/)
- [Building a faster web experience with the postTask scheduler](https://medium.com/airbnb-engineering/building-a-faster-web-experience-with-the-posttask-scheduler-276b83454e91)
In-depth overview for some of the concepts talked in the document:
- [`queueMicrotask()`](https://developer.mozilla.org/en-US/docs/Web/API/HTML_DOM_API/Microtask_guide)
- [The `requestAnimationFrame()` guide](https://flaviocopes.com/requestanimationframe/)
- [JavaScript Event Loop vs Node JS Event Loop](https://blog.insiderattack.net/javascript-event-loop-vs-node-js-event-loop-aea2b1b85f5c)
- [Using `requestIdleCallback()`](https://developers.google.com/web/updates/2015/08/using-requestidlecallback)
-->

0 comments on commit 82ebdf6

Please sign in to comment.