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

[docs] Avoid extracting classes twice #25973

Merged
merged 2 commits into from
Apr 27, 2021

Conversation

oliviertassinari
Copy link
Member

@oliviertassinari oliviertassinari commented Apr 25, 2021

updateStylesDefinition() is always called twice but once is enough. I have noticed this inefficiency when diving into #25928 (comment). I didn't benchmark the performance win.

I have used this as an opportunity to isolate what's for legacy components (JSS), so we can more easily remove the code later on.

Fix DateRangePickerDay classes extraction.

@oliviertassinari oliviertassinari added the docs Improvements or additions to the documentation label Apr 25, 2021
@mui-pr-bot
Copy link

mui-pr-bot commented Apr 25, 2021

Details of bundle changes

Generated by 🚫 dangerJS against 93a89d9

@eps1lon
Copy link
Member

eps1lon commented Apr 25, 2021

This will already be solved by #25933. Considering this does affect runtime (exporting styles will be dropped at some point), we should wait for #25933 instead.

@oliviertassinari
Copy link
Member Author

@eps1lon Should I update this PR to only salvage the fix on date-range-picker-day.json?

@oliviertassinari
Copy link
Member Author

@eps1lon Updated. My aim is to get the .json generated so that once we migrate to emotion, we can notice regressions.

Copy link
Member

@eps1lon eps1lon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you want to merge code that'll be removed in a couple of days, be my guest.

@oliviertassinari
Copy link
Member Author

@eps1lon What do you mean, will we kill the .json file for the docs? :)

@oliviertassinari oliviertassinari merged commit 9431d4a into mui:next Apr 27, 2021
@oliviertassinari oliviertassinari deleted the remove-wasted-CPU-cycles branch April 27, 2021 13:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Improvements or additions to the documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants