I am implementing Angular Universal (SSR) in Angular 14. The application builds without any issues when I run npm run build:ssr. Furthermore, I can successfully compile it using npm run dev:ssr. However, when I attempt to access the application via the compiled URL (e.g., http://localhost:4200), it presents an error with the message 'at XMLHttpRequest.send()' enter image description here

I encounter the same error when I run the npm run serve:ssr command. enter image description here

Does this error have any relation to the ports, such as HTTP and HTTPS?

app.server.module.ts enter image description here

main.server.ts enter image description here

tsconfig.server.json enter image description here

server.ts enter image description here

enter image description here

0

There are 0 answers