mirror of
https://github.com/visgl/react-map-gl.git
synced 2026-02-01 16:46:24 +00:00
Update map.md (#2396)
This commit is contained in:
parent
a36f1a3238
commit
e003343718
@ -577,7 +577,7 @@ import Map from 'react-map-gl';
|
||||
import type {MapRef} from 'react-map-gl';
|
||||
|
||||
function App() {
|
||||
const mapRef = useRef<MapRef>();
|
||||
const mapRef = useRef<MapRef>(null);
|
||||
|
||||
const onMapLoad = useCallback(() => {
|
||||
mapRef.current.on('move', () => {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user