“Re open last closed tab” causing to show last ajax request content

后端 未结 3 1867
清歌不尽
清歌不尽 2021-01-17 18:16

I am using HTML 5 history api to save state when ajax requests happen and i provide full html content if user request to same page with none ajax request.

\"Re-open

3条回答
  •  一个人的身影
    2021-01-17 18:37

    It all depends which browser you are using, and which optimisations are enabled.

    Google Chrome for instance will keep the page in memory, so when you hit back and it goes to a new site, or when you do re-open closed tab - it will restore the page from memory.

    Older/slower browsers will just refresh anything.

    Though this shouldn't really be a problem, as your javascript state should be restored as well - it should be exactly the same in every way when they re-open that page.

提交回复
热议问题