diff --git a/client/src/hooks/useUtils.ts b/client/src/hooks/useUtils.ts index 8f72a9a..3376459 100644 --- a/client/src/hooks/useUtils.ts +++ b/client/src/hooks/useUtils.ts @@ -47,4 +47,4 @@ export const useResizeObserver = ( return () => observer.disconnect() }, [ref, onResize]) -} \ No newline at end of file +} diff --git a/client/src/state/canvasStore.ts b/client/src/state/canvasStore.ts index 534fffd..fee5c0f 100644 --- a/client/src/state/canvasStore.ts +++ b/client/src/state/canvasStore.ts @@ -24,7 +24,7 @@ const INITIAL_STATE: CanvasState = { export const useCanvasStore = create()( devtools( persist( - (set, get) => ({ + (set) => ({ ...INITIAL_STATE, setCam: (x: number, y: number) => set({ camX: x, camY: y }), setZoom: (zoom: number) => set({ zoom }), diff --git a/client/src/utils/crdt.ts b/client/src/utils/crdt.ts index 73d636a..237ec92 100644 --- a/client/src/utils/crdt.ts +++ b/client/src/utils/crdt.ts @@ -36,4 +36,4 @@ export const destroyCRDT = () => { doc?.destroy() doc = null provider = null -} \ No newline at end of file +}