本文介绍了哪些浏览器具有后退缓存? (bfcache保留对DOM的修改)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

限时删除!!

当今哪些浏览器支持后退缓存(bfcache)?

Which browsers nowadays support a back-forwards cache (bfcache)?

后退缓存是浏览器的内存中缓存,当用户单击后退"按钮和前进"按钮时使用.它存储了用户离开时的页面状态,因此对DOM所做的任何更改都应立即加载.

A back-forwards cache is a browser's in-memory cache that is used when a user clicks the back button and the forward button. It stores the state of the page as it was when the user navigated away, so any changes made to the DOM should be loaded instantly.

请注意,这与所有浏览器都具有的常规缓存机制不同.当用户单击后退"按钮时,bfcache特别适用,并且可以处理DOM中的动态更改.

Note that this is different from the normal caching mechanisms that all browsers have. A bfcache applies specifically when a user clicks the back button, and can handle dynamic changes in the DOM.

我可以找到的有关bfcache的唯一信息是使用Firefox 1.5的历史了.现代浏览器支持吗?在哪里可以找到有关它的信息?

The only information I can find about this bfcache is years old, referencing Firefox 1.5. Do modern browsers support it? Where can I find information about it?

推荐答案

Firefox:是

Firefox支持后退缓存,您可以在此处找到详细信息:

Firefox: yes

Firefox supports a back-forwards cache, you can find details here:

  • Using Firefox 1.5 (back-forwards) caching
  • Working with BFCache (in Firefox)

请注意,尽管文档有多旧,但bfcache仍可以在较新的Firefox版本(例如75版)中运行.请注意,页面和扩展很容易意外停用bfcache.我发现我安装了一个扩展程序,该扩展程序在所有页面上都停用了bfcache.

Note that the bfcache does work in newer Firefox versions like version 75, despite how old the documentation is. Note that it is easy for pages and for extensions to deactivate the bfcache by accident. I found that I had an extension installed that deactivated the bfcache on all pages.

关于Safari,我只能找到这篇文章:

With regards to Safari, all I can find is this article:

  • WebKit Page Cache I – The Basics (2009) from webkit.org

本文指出,在所有使用HTTPS的页面上,页面缓存(其后向缓存的名称)已被禁用,在当今的Web中,页面缓存是其中的很大一部分.

This article states that the Page Cache (its name for the back-forwards cache) is disabled on all pages that use HTTPS, which in today's web, is a large portion of them.

Chrome浏览器不支持后退缓存.但是,他们的开发人员团队宣布他们正在探索将此功能添加到Chrome:

Chrome does not support a back-forwards cache. However, their developer team announced that they are exploring adding this feature to Chrome:

请参见此功能的chromestatus .

这篇关于哪些浏览器具有后退缓存? (bfcache保留对DOM的修改)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

1403页,肝出来的..

09-06 18:56