diff --git a/src/app/browse-by/browse-by-geospatial-data/browse-by-geospatial-data.component.html b/src/app/browse-by/browse-by-geospatial-data/browse-by-geospatial-data.component.html
index 9691ae02bc..6f09a5cfb3 100644
--- a/src/app/browse-by/browse-by-geospatial-data/browse-by-geospatial-data.component.html
+++ b/src/app/browse-by/browse-by-geospatial-data/browse-by-geospatial-data.component.html
@@ -1,13 +1,11 @@
{{ 'browse.metadata.map' | translate }}
- @if (isPlatformBrowser(platformId)) {
- @defer {
-
-
- }
+ @defer {
+
+
}
diff --git a/src/app/browse-by/browse-by-geospatial-data/browse-by-geospatial-data.component.ts b/src/app/browse-by/browse-by-geospatial-data/browse-by-geospatial-data.component.ts
index 333cb28e4f..6cb59e423a 100644
--- a/src/app/browse-by/browse-by-geospatial-data/browse-by-geospatial-data.component.ts
+++ b/src/app/browse-by/browse-by-geospatial-data/browse-by-geospatial-data.component.ts
@@ -6,9 +6,7 @@ import {
import {
ChangeDetectionStrategy,
Component,
- Inject,
OnInit,
- PLATFORM_ID,
} from '@angular/core';
import {
ActivatedRoute,
@@ -67,7 +65,6 @@ export class BrowseByGeospatialDataComponent implements OnInit {
public facetValues$: Observable = of(null);
constructor(
- @Inject(PLATFORM_ID) public platformId: string,
private searchConfigurationService: SearchConfigurationService,
private searchService: SearchService,
protected route: ActivatedRoute,
diff --git a/src/app/shared/geospatial-map/geospatial-map.component.ts b/src/app/shared/geospatial-map/geospatial-map.component.ts
index 7dc76d90b0..b4faccc768 100644
--- a/src/app/shared/geospatial-map/geospatial-map.component.ts
+++ b/src/app/shared/geospatial-map/geospatial-map.component.ts
@@ -37,6 +37,8 @@ import { GeospatialMapDetail } from './models/geospatial-map-detail.model';
* Component to draw points and polygons on a tiled map using leaflet.js
* This component can be used by item page fields, the browse-by geospatial component, and the geospatial search
* view mode to render related places of an item (e.g. metadata on a page), or items *as* places (e.g. browse / search)
+ *
+ * This component should be used in a `@defer` block to keep geospatial mapping libraries out of the main bundle!
*/
export class GeospatialMapComponent implements AfterViewInit, OnInit, OnDestroy {
diff --git a/src/app/shared/object-geospatial-map/object-geospatial-map.component.html b/src/app/shared/object-geospatial-map/object-geospatial-map.component.html
index 52d6d8176b..c2c995a579 100644
--- a/src/app/shared/object-geospatial-map/object-geospatial-map.component.html
+++ b/src/app/shared/object-geospatial-map/object-geospatial-map.component.html
@@ -1,3 +1,5 @@
-@if (isPlatformBrowser(platformId)) {
-
-}
+
+
diff --git a/src/app/shared/object-geospatial-map/object-geospatial-map.component.ts b/src/app/shared/object-geospatial-map/object-geospatial-map.component.ts
index b194b5e9c8..c4b3223bfa 100644
--- a/src/app/shared/object-geospatial-map/object-geospatial-map.component.ts
+++ b/src/app/shared/object-geospatial-map/object-geospatial-map.component.ts
@@ -41,7 +41,9 @@ import { parseGeoJsonFromMetadataValue } from '../utils/geospatial.functions';
/**
* This component is used with the GeospatialMap ViewMode in search or browse results, and
- * prepares geospatial data collection for display on the GeospatialMapComponent
+ * prepares geospatial data collection for display on the GeospatialMapComponent.
+ *
+ * This component should be used in a `@defer` block to keep geospatial mapping libraries out of the main bundle!
*/
export class ObjectGeospatialMapComponent {