Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,11 @@
"@solid-primitives/transition-group": "1.1.2",
"@solidjs/meta": "0.29.4",
"@tanstack/pacer-lite": "0.2.2",
"@tanstack/query-db-collection": "1.0.38",
"@tanstack/solid-db": "0.2.21",
"@tanstack/query-db-collection": "1.0.40",
"@tanstack/solid-db": "0.2.22",
"@tanstack/solid-form": "1.33.0",
"@tanstack/solid-hotkeys": "0.10.0",
"@tanstack/solid-query": "5.100.14",
"@tanstack/solid-query": "5.101.0",
"@tanstack/solid-table": "8.21.3",
"@ts-rest/core": "3.52.1",
"animejs": "4.2.2",
Expand Down Expand Up @@ -80,10 +80,10 @@
"@solid-devtools/overlay": "0.33.5",
"@solidjs/testing-library": "0.8.10",
"@tailwindcss/vite": "4.2.1",
"@tanstack/eslint-plugin-query": "5.100.3",
"@tanstack/solid-devtools": "0.8.2",
"@tanstack/solid-hotkeys-devtools": "0.6.6",
"@tanstack/solid-query-devtools": "5.100.3",
"@tanstack/eslint-plugin-query": "5.101.0",
"@tanstack/solid-devtools": "0.8.5",
"@tanstack/solid-hotkeys-devtools": "0.7.0",
"@tanstack/solid-query-devtools": "5.101.0",
"@testing-library/dom": "10.4.1",
"@testing-library/jest-dom": "6.9.1",
"@testing-library/user-event": "14.6.1",
Expand Down
13 changes: 1 addition & 12 deletions frontend/src/ts/collections/custom-themes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ export function useCustomThemesLiveQuery() {
const customThemesCollection = createCollection(
queryCollectionOptions({
staleTime: Infinity,
gcTime: Infinity, //remove when __nonReactive is removed
startSync: true,
queryKey: queryKeys.root(),
queryClient,
Expand All @@ -42,11 +43,6 @@ const customThemesCollection = createCollection(
`Error fetching custom themes: ${response.body.message}`,
);
}

if (_keepAlive === null) {
_keepAlive = useCustomThemesLiveQuery();
}

return response.body.data.map(applyIdWorkaround);
},
}),
Expand Down Expand Up @@ -177,10 +173,3 @@ export const __nonReactive = {
getCustomThemes,
getCustomTheme,
};

/**
* The collection gets cleaned up after a while.
* Keeping a query active fixes that. Remove when removing __nonReactive
*/
// oxlint-disable-next-line typescript/no-explicit-any
let _keepAlive: any = null;
7 changes: 1 addition & 6 deletions frontend/src/ts/collections/presets.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ export function usePresetsLiveQuery() {
const presetsCollection = createCollection(
queryCollectionOptions({
staleTime: Infinity,
gcTime: Infinity, //remove when __nonReactive is removed
queryKey: queryKeys.root(),
queryClient,
enabled: isAuthenticated,
Expand Down Expand Up @@ -204,9 +205,3 @@ export const __nonReactive = {
getPresets,
getPreset,
};

/**
* The collection gets cleaned up after a while.
* Keeping a query active fixes that. Remove when removing __nonReactive
*/
const _keepAlive = usePresetsLiveQuery();
15 changes: 1 addition & 14 deletions frontend/src/ts/collections/results.ts
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,7 @@ function normalizeResult(
const resultsCollection = createCollection(
queryCollectionOptions({
staleTime: Infinity,
gcTime: Infinity, //remove when __nonReactive is removed
queryKey: queryKeys.root(),
enabled: isAuthenticated,
queryFn: async () => {
Expand All @@ -243,13 +244,6 @@ const resultsCollection = createCollection(
);
setLastResult(lastResult);
}

if (_keepAlive === null) {
_keepAlive = useLiveQuery((q) =>
q.from({ results: resultsCollection }),
);
}

return results;
},
queryClient,
Expand Down Expand Up @@ -718,10 +712,3 @@ function getResults(): SnapshotResult<Mode>[] {
export const __nonReactive = {
getResults,
};

/**
* The collection gets cleaned up after a while.
* Keeping a query active fixes that. Remove when removing __nonReactive
*/
// oxlint-disable-next-line typescript/no-explicit-any
let _keepAlive: any = null;
7 changes: 1 addition & 6 deletions frontend/src/ts/collections/tags.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ const queryKeys = {
const tagsCollection = createCollection(
queryCollectionOptions({
staleTime: Infinity,
gcTime: Infinity, //remove when __nonReactive is removed
queryKey: queryKeys.root(),
queryClient,
enabled: isAuthenticated,
Expand Down Expand Up @@ -570,9 +571,3 @@ export const __nonReactive = {
getTag,
getActiveTags,
};

/**
* The collection gets cleaned up after a while.
* Keeping a query active fixes that. Remove when removing __nonReactive
*/
const _keepAlive = useTagsLiveQuery();
Loading
Loading