title: Mapbox blank map React-map-gl | ReactJS
body: <p>I am using react 17.0.1  and react-map-gl ^6.0.2 i have a map component.</p>
  <ol>
  <li>I have tried other libraries and the problem persists</li>
  <li>I have contacted support for mapbox</li>
  <li>I have contacted other mapbox users</li>
  </ol>
  <p>Couldnt solve that</p>
  <p>When i do &quot;npm run start&quot; no problem, it shows the map but when i do &quot;npm run build&quot; it only shows this:<a href="https://i.stack.imgur.com/xMpcs.png" rel="noreferrer">map blank</a></p>
  <p>And it throws this error : <a href="https://i.stack.imgur.com/UrAAu.png" rel="noreferrer">error</a></p>
  <p>My code bellow:</p>
  <pre><code>   import React, {useState } from &quot;react&quot;;
  import ReactMapGL from 'react-map-gl';
  const Map = () =&gt; {
    const[viewport, setViewport] = useState({
      width: &quot;100%&quot;,
      height: &quot;400px&quot;,
      latitude: 38.963745,
      longitude: 35.243322,
      zoom: 5
    });
       return (
      &lt;div&gt;
        &lt;h2&gt;Size yakın olan yerleri keşfedin!&lt;/h2&gt;
              &lt;ReactMapGL
                   {...viewport}
                onViewportChange={setViewport}
                mapboxApiAccessToken={process.env.REACT_APP_MAPBOX_ACCESS_TOKEN}
                mapStyle=&quot;mapbox://styles/mapbox/streets-v11&quot;
             /&gt;
            &lt;/div&gt;
             );
          }
       export default Map
  </code></pre>