Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[benchmark] Test styleFunctionSx vs. @styled-system/css #23702

Merged
merged 7 commits into from Nov 25, 2020

Conversation

mnajdova
Copy link
Member

@mui-pr-bot
Copy link

mui-pr-bot commented Nov 24, 2020

No bundle size changes

Generated by 🚫 dangerJS against 3da50f7

@oliviertassinari oliviertassinari added the benchmark We can't optimize what we can't measure label Nov 24, 2020
@oliviertassinari oliviertassinari changed the title [benchmark] Updated server benchmarks to test styleFunctionSx vs @styled-system/css [benchmark] Test styleFunctionSx vs @styled-system/css Nov 24, 2020
@oliviertassinari oliviertassinari changed the title [benchmark] Test styleFunctionSx vs @styled-system/css [benchmark] Test styleFunctionSx vs. @styled-system/css Nov 24, 2020
@oliviertassinari
Copy link
Member

@mnajdova I have tried to improve the benchmark, to simplify it. In the end, it seems that the following holds:

  1. React components: mean: 55.43ms
  2. Styled emotion: mean: 74.28ms
  3. Box Baseline: mean: 81.75ms
  4. Box Material-UI: mean: 184.21ms

It seems there is definitely an opportunity to improve performance, and that it's important :).
If we can get Box Material-UI from 184ms down to 120ms. It would make the cost of the Box, compared to class names move from x3.3 down to x2.1. It would make the cost of the Box compared to styled move from x2.5 down to x1.6.

@mnajdova
Copy link
Member Author

Let's merge than and compare per these benchmarks 👍

@mnajdova mnajdova merged commit 56c6881 into mui:next Nov 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
benchmark We can't optimize what we can't measure
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants