Open AntoineViau opened 7 years ago
For people curious about server and client side working together in a Universal project, this looks to be a good example: https://github.com/FrozenPandaz/ng-universal-demo
Yes I'd recommend that one as well. Also universal-starter should be updated soon as well
People who landed on this page might be interested on this demo version, which contains an API example retrieving data from an external web service. I also added support for LESS files. https://github.com/ofrebourg/ng-universal-demo
However, note that the use of ExtractTextPlugin in webpack.common.js broke the AOT build in that version. webpack.common.js contains a few commented lines with which AOT builds fine, but I'm not a big fan of that solution.
This repo is linked by the Angular 4.0.0-rc1 changelog. A lot of people, like myself, will eventually try the demo and spend some time try to understand the errors after doing a npm start.
This PR add client-side rendering (CSR) with angular-cli, along with server-side rendering (SSR). The readme is up-to-date. The main focus is to show one code working for SSR and CSR.