Investigate ServerStyleSheet construction performance
See original GitHub issueIt seems like new ServerStyleSheet()
is our biggest SSR perf bottleneck according to the SSR benchmarks added in #2119, which in turn makes it seem like StyleSheet.clone()
is the actual bottleneck.
Since as of v4 everything is in the component-context, I’m not 100% certain why we need to clone anything anymore on the server. It seems as though creating a cache of styles per each request should be a cheap operation since nothing should be shared anymore between requests?
Going to defer to @kitten’s expertise since he wrote most of that—can we maybe speed up or get rid of the cloning entirely?
Issue Analytics
- State:
- Created 5 years ago
- Comments:8 (7 by maintainers)
Top Results From Across the Web
Releases - styled-components
Prevent ServerStyleSheet from emitting empty style tags, which would cause issues in ... Big performance gain for components using style objects (see #3239)....
Read more >material-ui/core/CHANGELOG.md - UNPKG
This release widens the peer dependency scope of React to accept ^17.0.0. 32, The change makes it easier for developers to upgrade React...
Read more >styled components not working in prod nextjs - You.com
The performance of our custom dynamic styles implementation (based on props) isn't great (see the performance benchmarks below). This is seriously limiting ...
Read more >Planning Analytics for Microsoft Excel - IBM
Use Planning Analytics for Microsoft Excel without Performance Manager ... A log file is an important diagnostic tool for investigating the ...
Read more >An analysis of operating system behavior on a simultaneous ...
Redstone et al. investigated the performance of workloads running on a simulated SMT system with a full operating system [Redstone00] .
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@kitten that makes a lot of sense, thanks for the detailed write-up! Excited to see where this goes.
Closed thanks to v5!