-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
[DataGrid] Fix Maximum call stack size exceeded
error when using fractional width
#9516
[DataGrid] Fix Maximum call stack size exceeded
error when using fractional width
#9516
Conversation
Netlify deploy previewNetlify deploy preview: https://deploy-preview-9516--material-ui-x.netlify.app/ Updated pagesNo updates. These are the results for the performance tests:
|
@@ -122,7 +122,7 @@ export function useGridDimensions( | |||
}; | |||
|
|||
const scrollInformation = hasScroll({ | |||
content: { width: Math.round(columnsTotalWidth), height: rowsMeta.currentPageTotalHeight }, | |||
content: { width: columnsTotalWidth, height: rowsMeta.currentPageTotalHeight }, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In #9236 we started to use fractional size. Rounding the columns total width breaks the equality comparison
Hi. Sand box |
Thanks @AnastasiaEvgenia |
same error in "@mui/x-data-grid-pro": "7.1.1", anyone know how to fix? |
@gaisdav Are you sure it's the "Maximum call stack size exceeded" error? If the issue linked above is unrelated to the issue you're experiencing, please open a new issue with a minimal reproduction example. Thanks! |
@cherniavskii yes, let me show the error. I'm still trying to figure out why I'm getting this error in my case. |
@gaisdav Hmm, this looks like #11483 (comment) |
@cherniavskii |
Fixes #9510
Before: https://codesandbox.io/s/crimson-bash-7m8g6c?file=/demo.tsx
After: https://codesandbox.io/s/sad-pine-6c2j29?file=/demo.tsx