You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It reduces the bundle size. We can save the import for @emotion/hash.
The hash logic was added in the first place to handle server-side sheets caching. I have kept the hash version of the class name generator. Server-side caching is still a beta feature. It's gonna need more R&D. cc @kof
Glad you did this. JSS used hashes long time ago too, then I tried to optimize it this way too. I think I have now some ideas on how to avoid problems with mismatching class names after SSR by providing meaningful feedback to the user and documenting some edge cases. Once this is solved we are really good here!
I also think that we should make dev & prod class name output identical. It's soo frustrating to have something working in dev mode, to later see it broken in prod. I would rather make the compression optional.
I also think that we should make dev & prod class name output identical. It's soo frustrating to have something working in dev mode, to later see it broken in prod. I would rather make the compression optional.
Compression off by default or just allow to opt-out?
If the page has multiple react trees, the index counter breaks the css. Is there any way to handle this scenario? The hash version works perfectly with multiple react trees.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
performancescope: stylesSpecific to @mui/styles. Legacy package, @material-ui/styled-engine is taking over in v5.
4 participants
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
One slice of #14999.
This has different advantages:
https://next.material-ui.com/demos/buttons/#buttons
The hash logic was added in the first place to handle server-side sheets caching. I have kept the hash version of the class name generator. Server-side caching is still a beta feature. It's gonna need more R&D. cc @kof