getZoom() {
    let zoom;
    const resolution = this.getResolution();
    if (resolution !== undefined) {
      zoom = this.getZoomForResolution(resolution);
    }
    return zoom;
  }
Get the current zoom level. This method may return non-integer zoom levels
if the view does not constrain the resolution, or if an interaction or
animation is underway.
@return {number|undefined} Zoom.
@api