Bug: memory leak on deleting marker

Aperta
#1,419 1 commento 0 reazioni 1 assegnatario Vedi su GitHub

@wangela ci sta già lavorando.

Dal 22/2/2023.

Valutazione

Questa issue non è ancora stata valutata.

Descrizione

Operating system

Windows 10, 19045.2604

Browser Version

Chrome 110.0.5481.104

How severe is the bug?

high

Bug description

When trying to remove a marker from the map using setMap(null) and set the object and all known references to null, marker stays in memory.

Steps to reproduce

You can reproduce it with your own example:
https://jsfiddle.net/gh/get/library/pure/googlemaps/js-samples/tree/master/dist/samples/marker-remove/jsfiddle

  1. open the url
  2. create a heap memory dump in developer tools
  3. search for "_.wh". There are four objects
  4. click on "delete markers" in jsfiddle
  5. click on garbage collector in developer tools
  6. create a new heap memory dump in developer tools
  7. search for "_.wh". There should be one less, but still four availble.
Console log output

No response

Lingua principale
TypeScript
Stelle
804
Fork
826
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di googlemaps/js-samples

Tutte le issue di googlemaps/js-samples

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.