dispose method

void dispose()

Implementation

void dispose() {
  debugPrint("delete frame_map_$mapIdMixin");
  debugPrint("delete osm_map_$mapIdMixin");
  html.window.document.getElementById("frame_map_$mapIdMixin")?.remove();
  html.window.document.getElementById("osm_map_$mapIdMixin")?.remove();
  //_div.remove();
  _frame?.remove();
  _frame = null;
  //mapScript?.remove();
  webPlatform.close(mapIdMixin);
  channel = null;
  webPlatform.mapsController.removeWhere((key, value) => key == mapIdMixin);
}