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

180
Vistas
Detect when here map is done rendering

There is an issue with detecting when the map has rendered the markers.

I have added a listener to the 'render' event:

mapEngine.addEventListener('render', onRenderChange)

and wait for the event to return the map engine to know when the rendering is done as I have seen as an answer for a similar question here.

function onRenderChange(evt) {
    if (map.getEngine() === evt.target) {
        //render is done    
    }
}

The result is that the listener returns the map engine multiple times (about 40-45 times for the render of 200 markers and the number of times seems random with every refresh).

Furthermore, sometimes the map pauses the rendering for some time (1-2s) and then continues. This happens when rendering changes in existing markers (such as change a marker's position).

What is an accurate way of knowing when the map is done rendering?

I use the HERE maps API for JavaScript v3.0 in an angular project.

The icon is a single global SVG icon reused for all the markers. I have also tried with a PNG icon with the same results.

A group 'markersGroup' is added to the map when the map is initialized. The markers are being added to the map in bulk using:

    markersGroup.addObjects(markersToAdd);

where markersToAdd is an array of markers (H.map.Marker).

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

0

Map JavaScript API 3.0 is deprecated. I would recommend using 3.1.

Typically, the map is rendered one time while adding a grouped objects. The 40-45 times for the render of a group of 200 markers looks unusual. Not sure if it is caused by Angular. Could you try JavaScript API 3.1? if the issue remains, please share the snippet codes.

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