refacto : cleaning the codebasebase again

This commit is contained in:
2026-04-19 16:50:11 +02:00
parent f9c4495610
commit dcbc1c73f5
26 changed files with 127 additions and 5726 deletions
+2 -12
View File
@@ -1,8 +1,6 @@
import { useSyncExternalStore } from "react";
import {
InteractionManager,
type InteractionSnapshot,
} from "@/stateManager/InteractionManager";
import { InteractionManager } from "@/stateManager/InteractionManager";
import type { InteractionSnapshot } from "@/types/interaction";
const manager = InteractionManager.getInstance();
@@ -12,11 +10,3 @@ export function useInteraction(): InteractionSnapshot {
manager.getState.bind(manager),
);
}
export function useInteractionSelector<T>(
selector: (state: InteractionSnapshot) => T,
): T {
return useSyncExternalStore(manager.subscribe.bind(manager), () =>
selector(manager.getState()),
);
}