Este es un error que no entiendo TypeError: Cannot read properties of undefined (reading 'getCameraForLocationToPoint')
Recibí este error cuando intento crear un Bingmap para mi proyecto angular
.TS
let loc = new Microsoft.Maps.Location(Latitude,Longitude); this.map.setView({ center: { latitude: loc.latitude, longitude: loc.longitude }}); this.map.setView({ mapTypeId: Microsoft.Maps.MapTypeId.streetside }); Microsoft.Maps.Events.addHandler(this.map, 'viewchangeend', () => { this.updateView(this.map); }); this.updateView(this.map); Microsoft.Maps.Events.addHandler(this.map, 'click', this.Clicked.bind(this.map)); streetViewMapPromise(promise: Promise<any>) { promise.then(x => { this.map = x; }) } Clicked(e){ //click event console.log(e) }.html
<app-rs-bingmap (MapPromise)="streetViewMapPromise($event)" [options]="_mapOptions"></app-rs-bingmap>La sección anterior es mi sección de importación de componentes de Bingmap v8. Además, mi evento de clic tampoco funciona. cuando hago clic en el mapa que quiero mostrar y alertar.
Aquí está el error stackblitz: getCameraForLocationToPoint aquí