maplibre-react-native
maplibre-react-native copied to clipboard
Interface PointAnnotationProps should have functions take an Event argument
Events function in PointAnnotationProps create a TypeScript error because their interface don't allow for any arguments to be passed
export interface PointAnnotationProps extends ViewProps {
id: string;
title?: string;
snippet?: string;
selected?: boolean;
draggable?: boolean;
coordinate: GeoJSON.Position;
anchor?: Point;
onSelected?: () => void;
onDeselected?: () => void;
onDragStart?: () => void;
onDrag?: () => void;
onDragEnd?: () => void;
}
Overload 2 of 2, '(props: PointAnnotationProps, context: any): PointAnnotation', gave the following error. Type '(e: any) => void' is not assignable to type '() => void'.ts(2769)
What version of maplibre-react-native are you using? And am I understanding correctly you are refering to the onDrag, onSelected, ... functions?
What version of maplibre-react-native are you using? And am I understanding correctly you are refering to the
onDrag,onSelected, ... functions?
Version 9.0.1 Yes, those functions :)
This is fixed on the latest v10 pre-releases.