Open jbouhier opened 1 year ago
Wow, good timing, I am facing the exact same problem.
@jbouhier Here, this worked for me:
// extraTypings.d.ts import * as ReactSimpleMaps from "react-simple-maps";
declare module "react-simple-maps" {
export function useZoomPanContext(): {x: number; y: number; k: number; transformString: string;};
}
@richardfinegan I was looking for this workaround. Thank you!
@jbouhier Were you able to use useZoomPanContext()
in your app? When I call const ctx = useZoomPanContext()
, the return value is undefined.
I'm using
react-simple-maps
+@types/react-simple-maps
v3.0.0.useZoomPanContext
and all the other hooks from the docs are missing from@types/react-simple-maps
's type declarations.How can I help to fix that @zimrick ?