## Removing repetitive queries (impacting performance on page load) We have recently introduced the capability to detect schema version mismatch. To do that, we add a new header in all our queries. On page load, this header is added once we know the currentUser and especially its currentWorkspace and related schema version. However, applying this header to apollo client will re-trigger all queries that have been already performed (GetClientConfig and GetCurrentUser). To avoid re-triggering them, I'm introducing two new "isLoaded" states and skip the query if the query has already been performed ## Fixing Relation Detail not displaying data on show page Small bug introduced in a previous PR
7 lines
169 B
TypeScript
7 lines
169 B
TypeScript
import { createState } from 'twenty-ui';
|
|
|
|
export const isClientConfigLoadedState = createState<boolean>({
|
|
key: 'isClientConfigLoadedState',
|
|
defaultValue: false,
|
|
});
|