mui-x icon indicating copy to clipboard operation
mui-x copied to clipboard

[DataGrid] Improve `GridRowModel` typing

Open cherniavskii opened this issue 3 years ago • 1 comments
trafficstars

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

cherniavskii avatar Aug 08 '22 12:08 cherniavskii

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

mui-bot avatar Aug 08 '22 12:08 mui-bot

@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

cherniavskii avatar Aug 22 '22 18:08 cherniavskii

Okay

flaviendelangle avatar Aug 24 '22 10:08 flaviendelangle