react / react/react

Bug: Webpack process and setImmediate polyfill interferes with time slicing

Open
#21,685 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Component: Concurrent Features React 18 Type: Bug
Dominant language
JavaScript
Stars
251k
Forks
51.4k
Avg merge
2d 4h
Merged PRs (30d)
53

Description

Here's the copy paste of the polyfill: https://gist.github.com/gaearon/5d2f7bedf76d7bbec2b5c1ee04861ce3

This reproes with old CRA (e.g. react-scripts@0.7.0). I saw this on this branch: https://github.com/Swizec/react-fractals/pull/16

The result is concurrent renders get grouped into a huge blocking task:

Screenshot 2021-06-15 at 18 01 27

Not sure why yet.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading the linked setImmediate polyfill and reproducing the issue with old CRA, such as react-scripts@0.7.0, using the react-fractals pull request example. Investigate why concurrent renders become one large blocking task. Done means the cause is isolated and a verified fix or regression test addresses the interaction.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, react, webpack
Domain
build-system, frontend, performance
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.