I am using a custom widget which is used to draw an extent and retrieve the XMax,Xmin,YMax,YMin values of the used Map Service but in WAB it is returning the extent values of the basemap. Also, the spatial reference is different for both Map Service and BaseMap.
How Can I get the Map Service's extent values??