-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
[docs] Improve the docs of updateRows #5949
Comments
I fails when called with several rows. That's the same topic again, the apiRef is available on community plan, so technically people can use it. However it's only available on slots so in a real scenario, most of the time the apiRef is pro only. |
@flaviendelangle Ah, I didn't notice that there was a valid use case with the community plan. My bad, thanks. I'm confused then. What's the different with calling |
The performances of calling it N times would be catastrophic |
@flaviendelangle Ok thanks, I feel that I understand the problem space now.
Both handle 1,000 row updates per second. There is a difference, it's 70% faster, sounds like it's worth having in the Pro plan then. As a follow-up, I would propose:
diff --git a/packages/grid/x-data-grid/src/DataGrid/DataGrid.tsx b/packages/grid/x-data-grid/src/DataGrid/DataGrid.tsx
index 7058730b1..11f7ae3ee 100644
--- a/packages/grid/x-data-grid/src/DataGrid/DataGrid.tsx
+++ b/packages/grid/x-data-grid/src/DataGrid/DataGrid.tsx
@@ -1,6 +1,6 @@
import * as React from 'react';
import PropTypes from 'prop-types';
-import { chainPropTypes } from '@mui/utils';
+import { exactProp, chainPropTypes } from '@mui/utils';
import {
GridBody,
GridErrorHandler,
@@ -748,3 +748,8 @@ DataGridRaw.propTypes = {
PropTypes.object,
]),
} as any;
+
+
+if (process.env.NODE_ENV !== 'production') {
+ DataGridRaw.propTypes = exactProp(DataGridRaw.propTypes as any);
+} Which with https://codesandbox.io/s/peaceful-shannon-qrsfzv?file=/demo.tsx codesandbox would turn into:
https://mui.com/x/api/data-grid/grid-api/#properties
|
|
|
For 4., I think this is a good example of a feature that people can name very differently depending on what they have in mind. Like for the Master / Detail panel |
Seems the docs for Another thing I noticed about the docs is there is no summary of which features You don't really find out a feature is unsupported by the base plan until you write some code and execute it without complete documentation... If |
@morganney I think the Do you have a particular case where it doesn't work? If yes, could you share a minimal reproduction of the problem here? |
Duplicates
Latest version
Current behavior 😯
https://mui.com/x/api/data-grid/grid-api/
Expected behavior 🤔
Steps to reproduce 🕹
No response
Context 🔦
This is documented as Pro only in https://mui.com/x/react-data-grid/row-updates/#the-updaterows-method, and fails when called:
mui-x/packages/grid/x-data-grid/src/hooks/features/rows/useGridRows.ts
Lines 152 to 160 in e59e909
Your environment 🌎
v5.16.0
Order ID 💳 (optional)
No response
The text was updated successfully, but these errors were encountered: