Open BlindDespair opened 2 years ago
@BlindDespair do you have a sample site we can look at?
@aaronfrost do you mean a repo or just a url to a deployed site. Sadly I do not have a sample site which demonstrates this deployed anywhere although we do have 1 production site with this. Although I pretty much summed it up in the description, generating any app with scully will produce 404.html
and that should contain the info about it being pre-rendered by scully just like any page.html
🐞 Bug report
Description
We have certain pages that require authentication and therefore wish not to prerender them.
I am using
'ignored'
router plugin on those pages and our CDN returns404.html
when trying to open them and it gets rendered on the client side by angular correctly, but an issue arises when you first open site on such page which is not prerendered and then you try navigating to a page that was prerendered using Angular navigation, in this casewindow['ScullyIO']='generated'
is missing andTransferStateService
does not fetchdata.json
but instead does the requests to our CMS which should not happen.Navigating to non-prerendered pages from a prerendered page does not cause any issues and everything works correctly so I think that
404.html
should containwindow['ScullyIO']='generated'
to make sure that TransferStateService behaves consistently regardless of which page users enters the site at.🔬 Minimal Reproduction
Generate any angular application with scully and check contents of
404.html
💻Your Environment
Angular Version:
Scully Version: