Thank you for helping me troubleshoot this error.
I think some of the problems were related to old node packages.
Running the following commands helped:
cd D:\apps\dspace-angular-dspace-9.1
npm run clean
npm install
npm run build:prod
This allows pages like the /statistics to successfully load from typing the address in a browser.
Handle links are not loading successfully the first time but a browser reload works. I have attached the full log.
Redirecting from /handle/10342/4284 to /items/67ac1577-0993-4a96-b6cf-18a0fcc5ada0 with 301
GET /handle/10342/4284 301 396.718 ms - 84
Warning [ERR_HTTP_HEADERS_SENT]: Tried to set headers after they were sent to the client
Error: Cannot set headers after they are sent to the client
at ServerResponse.setHeader (node:_http_outgoing:700:11)
at ServerResponse.res.set.res.header (C:\apps\dspace-angular-dspace-9.1\dist\server\main.js:1:2999582)
at ServerResponse.res.send (C:\apps\dspace-angular-dspace-9.1\dist\server\main.js:1:2993950)
at C:\apps\dspace-angular-dspace-9.1\dist\server\main.js:1:8089795
at _ZoneDelegate.invoke (C:\apps\dspace-angular-dspace-9.1\dist\server\main.js:1:3941414)
at ZoneImpl2.run (C:\apps\dspace-angular-dspace-9.1\dist\server\main.js:1:3933987)
at C:\apps\dspace-angular-dspace-9.1\dist\server\main.js:1:3952322
at _ZoneDelegate.invokeTask (C:\apps\dspace-angular-dspace-9.1\dist\server\main.js:1:3942256)
at ZoneImpl2.runTask (C:\apps\dspace-angular-dspace-9.1\dist\server\main.js:1:3935056)
at drainMicroTaskQueue (C:\apps\dspace-angular-dspace-9.1\dist\server\main.js:1:3945490)
GET /items/67ac1577-0993-4a96-b6cf-18a0fcc5ada0 - - ms - -
Thanks,
Nick