Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Reactathon 2023 - Concurrent React Made Easy

Reactathon 2023 - Concurrent React Made Easy

Henrique Inonhe

May 03, 2023
Tweet

More Decks by Henrique Inonhe

Other Decks in Programming

Transcript

  1. • Input Fields • Buttons • Menus • Sliders •

    “Smaller” UI Units • Huge List • Dashboard • Spreadsheet • Navigations • “Bigger” UI Units
  2. Synchronous Rendering Update! Main Thread (Your JS code runs here)

    Render Event Event Event Event Event Event
  3. Prioritization Without With !!! !!! !!! !! !! ! !

    ! !!! !!! !!! !! !! ! ! ! Interruptibility Without With
  4. High Priority Renders Low Priority Renders • Synchronous • Blocking

    • Non-interruptible • Interrupt low priority renders • Asynchronous • Non-blocking • Interruptible • Run after high priority renders
  5. Low Priority Renders • Asynchronous • Non-blocking • Interruptible •

    Run after high priority renders High Priority Renders • Synchronous • Blocking • Non-interruptible • Interrupt low priority renders
  6. High Priority Renders • Synchronous • Blocking • Non-interruptible •

    Interrupt low priority renders Low Priority Renders • Asynchronous • Non-blocking • Interruptible • Run after high priority renders