1
0
mirror of https://github.com/Unleash/unleash.git synced 2024-10-18 20:09:08 +02:00
unleash.unleash/frontend/src
Nuno Góis 233e06ec6a
fix: disable autoResetHiddenColumns when useConditionallyHiddenColumns (#2851)
https://linear.app/unleash/issue/2-563/fix-issue-with-useconditionallyhiddencolumns-and-react-table

It seems like we should add `autoResetHiddenColumns: false` to
`useTable` whenever we use `useConditionallyHiddenColumns`.

Basically the thought is that, if we're controlling column visibility in
our own way, we should not want other things to change that state
unpredictably, otherwise this may make React go _brrrrrr_. And it can be
very hard to pinpoint what exactly may be causing React to go _brrrrrr_.


![image](https://user-images.githubusercontent.com/14320932/211332339-95918c5c-e3ea-40e9-b8b4-756a798a4702.png)

First detected this issue apparently randomly while developing the new
SA table. Around 10-20 page refreshes would eventually trigger it. Was
not easy to find, but hopefully this fixes it permanently. At least I
haven't been able to reproduce it since. Maybe someone has a better idea
of where the issue could be or if this is a pretty good guess. Doesn't
seem like this change hurts us anyways.

I love React, `useEffect` and these very to-the-point error messages.
Very fun and productive.

Reference: https://react-table-v7.tanstack.com/docs/api/useTable
2023-01-10 08:15:12 +00:00
..
__mocks__
assets
component fix: disable autoResetHiddenColumns when useConditionallyHiddenColumns (#2851) 2023-01-10 08:15:12 +00:00
constants Feat clone environment modal (#2245) 2022-10-28 09:15:46 +01:00
contexts Custom event tracking (#2151) 2022-10-10 14:06:44 +02:00
hooks Feat sa table info (#2848) 2023-01-09 16:18:37 +00:00
interfaces Feat sa table info (#2848) 2023-01-09 16:18:37 +00:00
openapi Orval generator POC (#2724) 2023-01-05 11:57:53 +01:00
themes Refactor makestyles 2 2 (#2827) 2023-01-05 16:23:40 +02:00
types chore(deps): update dependency prettier to v2.8.1 (#2509) 2022-12-27 10:45:43 +01:00
utils Orval generator POC (#2724) 2023-01-05 11:57:53 +01:00
index.tsx feat: message banner (#2726) 2022-12-22 15:16:51 +00:00
setupTests.ts feat: new tag types table (#1014) 2022-05-25 11:12:53 +02:00
vite-env.d.ts