angular / universal-starter

Angular Universal starter kit by @AngularClass
2.02k stars 688 forks source link

Multiple runs of prerender causes flicker #475

Open rbren opened 6 years ago

rbren commented 6 years ago

Ran into one issue when running the prerender script: if the homepage is prerendered, and the prerender script is run multiple times, it will cause a flickering issue on all prerendered pages.

More details:

Suggested fix

Have the prerender script make a copy of dist/browser/index.html at dist/browser/original_index.html, and load that file instead of index.html if it exists

rbren commented 6 years ago

PS - I'm happy to implement and send a PR if you guys think this is the right solution.