I am using create react app, along with react-map-gl
. I just need the map to show up on the screen right now but all it does is show the mapbox logo and have a blank space where the map should be.
Here is my main .js file:
import './App.css';
import ReactMapGL from 'react-map-gl';
import React, {useState} from 'react';
function App() {
const [viewport, setViewport] = useState({
width: 400,
height: 400,
latitude: 38.958630,
longitude: -77.357002,
zoom: 10
});
return (
<div className="TextStuff">
<ReactMapGL {...viewport}
mapboxApiAccessToken={process.env.REACT_APP_MAPBOX_TOKEN}>MAPPPPP</ReactMapGL>
</div>
);
}
export default App;