+/** From EPSG:4326 lat/lon to a proj lon/lat */
+export function transformToOlLonLatExtent(extent, projection) {
+ const proj = projection.getCode();
+ if (proj === 'EPSG:4326')
+ return toLonLatExtent(extent);
+ const reordered = toLonLatExtent(extent);
+ var transformed = transformExtent(reordered, 'EPSG:4326', proj);
+ return transformed;
+}
+
+/** Converts from an extent in OpenLayers order (lon/lat) to WFS 2.0 order (lat/lon). */