Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

359
Vistas
React Map GL: map not taking the width and height after opening inspect

I am using react map gl to render maps in my react application. But the Maps rendered from react-map-gl are not taking the width after opening inspect and, sometimes not restoring back to normal after shrinking the window

This is my setting for the viewport,

 const mapStyle = {
        height: '100vh',
        width: '60vw',
        zoom: 15
    }

Please find the image below: The left side is reserved for showing extra information

At first, it works as expected

enter image description here

After opening a inspect and closing the sidebar, the map shrinks like this

enter image description here

enter image description here

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

On which react-map-gl version are you? I noticed that in v7 height and width fields in viewState, former viewport, do not exist anymore. Not sure if related.

about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda