Angular Universal SSR not rendering API content in production (Nginx + Laravel API)

Discussão em 'Angular' iniciado por Alejandro Gómez, Fevereiro 19, 2025.

  1. I am working on an Angular 15 application with Universal (SSR). Locally, everything works fine, but in production, the SSR content is not rendered correctly.

    Setup: Frontend: Angular 15 with Universal Backend: Laravel API Local environment: Laravel running with php artisan serve Production environment: Laravel API hosted on a domain using Nginx Issue: When I run npm run dev:ssr, everything works fine. Meta tags and the HTML inside are correctly updated with API data. However, in production: When I execute npm run build:ssr && npm run serve:ssr or ng run app:serve-ssr:production, the API data is not rendered in the HTML.

    It seems that if the data takes a bit to load, the html is not updated.

    Continue reading...

Compartilhe esta Página