I have a problem with the map display in React Leaflet - I installed everything, but it still doesn't work...
What do I have to change? I added css, added height but do not know what is missing
import React from "react";
import { MapContainer, Marker, Popup, TileLayer, useMap } from "react-leaflet";
import "leaflet/dist/leaflet.css";
const ProjectAnalysis = () => {
return (
<div>
<p>bok</p>
<MapContainer
center={[51.505, -0.09]}
zoom={13}
scrollWheelZoom={true}
style={{ width: "100%", height: "calc(100vh - 4rem)" }}
>
<TileLayer
url="http://{s}.tile.osm.org/{z}/{x}/{y}.png"
attribution='© <a href="http://osm.org/copyright">OpenStreetMap</a> contributors'
/>
<Marker position={[51.505, -0.09]}>
<Popup>
A pretty CSS3 popup. <br /> Easily customizable.
</Popup>
</Marker>
</MapContainer>{" "}
<p>bok</p>
</div>
);
};
export default ProjectAnalysis;