Let's say that you receive a link that takes you to a page from a single page application. You want to be able to see that page instantly (of course, if you are logged in).
The issue is that the data is not fetched from the server, so the page is empty.
Which practice is the best to fetch all the necessary data to be able to see that page correctly?. Basically, when refreshing the page, you want to remain in that place, not to be redirected to "/"(for example).
I thought about making a separate component which fetch all the data and when its all done, render the page. But, it comes with a downside, which is double fetching of data on normal usage of application.