I'm sure there is exceptions, but in general, the last thing I want my browser to do when i press back, is to start making requests. I expect the requests to have been already made.
I'm sure there is exceptions, but in general, the last thing I want my browser to do when i press back, is to start making requests. I expect the requests to have been already made.
My daily use case for this is Github Issues. Simple repro: Click an issue, make a change, press back.
Now the list view is out of date and doesn't show my changes. So I have to refresh.
I think a background XHR request is the best approach (until browsers fix this issue for real). On page load: pull latest from server (if network is down, then no-op). If no changes, then don't change. If there are changes then replace inline without a new page reload.
If I click back I want to see what I saw last time. e.g. I might have seen 3 news articles I was interested in, I click though and read the first one. When I click back I want to see the exact same list as before, and be able to read the next article I saw; not new articles that have been written while I was reading the last one.
You can s/news article/github issue/ and my response is the same.
Okay. C-r is quick and easy to type. But if Back automatically destroys the old version of the page, then there is no way to restore that old page.
> My daily use case for this is Github Issues. Simple repro: Click an issue, make a change, press back.
> Now the list view is out of date and doesn't show my changes. So I have to refresh.
How is that different from one tab with the list of issues, and one tab with a specific issue? In the tab instance, GitHub has added JavaScript to the issue list page to refresh on changes; in the Back button instance, it should work identically: the list view is 'rehydrated,' the JavaScript does its thing and the list view is updated.
Reloading the page is completely, totally wrong.