Removed use-context-selector completely (#12139)

This PR removes use-context-selector completely, so that any bug
associated with state synchronization between recoil and
use-context-selector disappears.

There might be a slight performance decrease on the table, but since we
have already improved the average performance per line by a lot, and
that the performance bottleneck right now is the fetch more logic and
the windowing solution we use, it is not relevant.

Also the DX has become so hindered by this parallel state logic recently
(think [cache
invalidation](https://martinfowler.com/bliki/TwoHardThings.html)), that
the main benefit we gain from this removal is the DX improvement.

Fixes https://github.com/twentyhq/twenty/issues/12123
Fixes https://github.com/twentyhq/twenty/issues/12109
This commit is contained in:
Lucas Bordeau
2025-05-20 13:35:28 +02:00
committed by GitHub
parent 9ba24b3654
commit 0553f58c52
30 changed files with 408 additions and 697 deletions

View File

@ -55579,7 +55579,6 @@ __metadata:
tsx: "npm:^4.17.0"
type-fest: "npm:4.10.1"
typescript: "npm:5.3.3"
use-context-selector: "npm:^2.0.0"
use-debounce: "npm:^10.0.0"
uuid: "npm:^9.0.0"
vite: "npm:^5.4.0"
@ -56763,16 +56762,6 @@ __metadata:
languageName: node
linkType: hard
"use-context-selector@npm:^2.0.0":
version: 2.0.0
resolution: "use-context-selector@npm:2.0.0"
peerDependencies:
react: ">=18.0.0"
scheduler: ">=0.19.0"
checksum: 10c0/4eb6054ab8996ae8b3f87f9d102e576066e5a8b9db5db2c891128ae920bd64bcdcb4e93a13bc99658ef16280929a8331fc8ac45177f4acd716c425b1bc31135a
languageName: node
linkType: hard
"use-debounce@npm:^10.0.0":
version: 10.0.2
resolution: "use-debounce@npm:10.0.2"