mui-x
mui-x copied to clipboard
[DataGrid] Improve `GridRowModel` typing
Fixes https://github.com/mui/mui-x/pull/5214#discussion_r939047535
It makes much more sense to always treat grid row model as an object rather than any
These are the results for the performance tests:
| Test case | Unit | Min | Max | Median | Mean | σ |
|---|---|---|---|---|---|---|
| Filter 100k rows | ms | 349.8 | 762.5 | 404 | 492.36 | 160.68 |
| Sort 100k rows | ms | 482.8 | 876.7 | 828.6 | 765.26 | 143.459 |
| Select 100k rows | ms | 145 | 283 | 208.1 | 220.78 | 50.651 |
| Deselect 100k rows | ms | 144.8 | 242.4 | 198.7 | 193.46 | 34.975 |
Generated by :no_entry_sign: dangerJS against 1c92d89132da142d6aef7847881af0874262c53f
@flaviendelangle That would require way more work and will potentially lead to a lot of breaking changes.
Also, I experienced few issues with generic constraints in callbacks like gridCellParams similar to https://www.typescriptlang.org/docs/handbook/2/functions.html#working-with-constrained-values
This PR does fix https://github.com/mui/mui-x/pull/5214#discussion_r939047535 though
Okay