From bd0dea9781d7d30cb10846e088f336121be96044 Mon Sep 17 00:00:00 2001
From: rschoene <rene.schoene@tu-dresden.de>
Date: Fri, 9 Sep 2022 14:55:50 +0200
Subject: [PATCH] Set base-href, and use HashLocationStrategy

---
 Dockerfile            | 3 ++-
 build-view.sh         | 2 +-
 src/app/app.module.ts | 2 +-
 3 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/Dockerfile b/Dockerfile
index b4244c4..d2dcde5 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -6,4 +6,5 @@ RUN npm install -g @angular/cli@11.1.1
 VOLUME ["/data"]
 VOLUME ["/dist"]
 RUN chmod +x build-view.sh
-ENTRYPOINT ["/bin/sh"]
+ENV BASE_HREF="."
+ENTRYPOINT [""]
diff --git a/build-view.sh b/build-view.sh
index 6ed2a5a..dc95c8e 100755
--- a/build-view.sh
+++ b/build-view.sh
@@ -1,2 +1,2 @@
 #!/bin/sh
-ng build --base-href . --delete-output-path=false $@
+ng build --base-href ${BASE_HREF:-.} --delete-output-path=false $@
diff --git a/src/app/app.module.ts b/src/app/app.module.ts
index de1f12b..20ae9b8 100644
--- a/src/app/app.module.ts
+++ b/src/app/app.module.ts
@@ -29,7 +29,7 @@ import { AstDeclComponent } from './ast-decl/ast-decl.component';
         path: 'source/:filename/:line',
         component: SourceViewComponent
       }
-    ]),
+    ], { useHash: true }),
   ],
   declarations: [
     AppComponent,
-- 
GitLab