Skip to content

Conversation

bvaughn
Copy link
Contributor

@bvaughn bvaughn commented Feb 23, 2021

Use the pre-built scheduler (which includes a check for 'window' being defined in order to load the right scheduler implementation) rather than just directly importing a version of the scheduler that relies on window. Since the scheduling profiler's code runs partially in a web worker, it can't rely on window.

Alternate fix for #20865.

Use the pre-built scheduler (which includes a check for 'window' being defined in order to load the right scheduler implementation) rather than just directly importing a version of the scheduler that relies on window. Since the scheduling profiler's code runs partially in a web worker, it can't rely on window.
@facebook-github-bot facebook-github-bot added CLA Signed React Core Team Opened by a member of the React Core Team labels Feb 23, 2021
@sizebot
Copy link

sizebot commented Feb 23, 2021

Comparing: e5f6b91...39dc783

Critical size changes

Includes critical production bundles, as well as any change greater than 2%:

Name +/- Base Current +/- gzip Base gzip Current gzip
oss-stable/react-dom/cjs/react-dom.production.min.js = 122.36 kB 122.36 kB = 39.41 kB 39.41 kB
oss-experimental/react-dom/cjs/react-dom.production.min.js = 128.94 kB 128.94 kB = 41.47 kB 41.47 kB
facebook-www/ReactDOM-prod.classic.js = 404.67 kB 404.67 kB = 75.15 kB 75.15 kB
facebook-www/ReactDOM-prod.modern.js = 393.02 kB 393.02 kB = 73.24 kB 73.24 kB
facebook-www/ReactDOMForked-prod.classic.js = 404.68 kB 404.68 kB = 75.15 kB 75.15 kB

Significant size changes

Includes any change greater than 0.2%:

(No significant changes)

Generated by 🚫 dangerJS against 39dc783

@bvaughn bvaughn merged commit 4190a34 into facebook:master Feb 23, 2021
@bvaughn bvaughn deleted the scheduling-profiler-use-prebuilt-scheduler branch February 23, 2021 17:15
koto pushed a commit to koto/react that referenced this pull request Jun 15, 2021
Use the pre-built scheduler (which includes a check for 'window' being defined in order to load the right scheduler implementation) rather than just directly importing a version of the scheduler that relies on window. Since the scheduling profiler's code runs partially in a web worker, it can't rely on window.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed React Core Team Opened by a member of the React Core Team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants