Open ghost opened 4 years ago
You should run npm run serve:ssr
after running npm run build:ssr
or npm run build:prod
.
ok, I did npm run serve:ssr, it says: Node Express server listening on http://localhost:4000
it looks ok, but the pages are not SSR.
it looks ok, but the pages are not SSR.
Are you sure about that? I have run lighthouse audit on the localhost page by using Chrome DevTools and pretty much it has almost 100% score on SSR. Same after being deployed on AWS.
well, I opened Chrome, I typed http://localhost:4000, displayed the page, right click, View Page Source and what is displayed it is the same as a normal angular running on web browser.
That's the idea, in order to truly test if ssr works is by using curl -i localhost:4000
and see if the resulting response is the same as the normal one.
ok, thanks.
I can do npm run build:prod but I get this error:
npm ERR! missing script: server
when I npm run server.
so I can I run the ssr version?