javascript - framework7 防止缓存页面数据

标签 javascript html cordova html-framework-7

我想阻止 Framework 7 中所有应用程序的页面缓存。我可以在此处添加任何选项吗

var myApp = new Framework7({
        material: true //enable Material theme
    })

或者可以让我永久停止缓存的功能。

最佳答案

你可以设置cache: false

var myApp = new Framework7({
    cache: false /* disable caching */
})

或者(如果它更适合您的应用程序)您可以将其持续时间设置为零,设置 cacheDuration: 0 如下

var myApp = new Framework7({
    cacheDuration: 0 /* set caching expire time to 0 */
})

可以引用http://framework7.io/docs/init-app.html了解更详细的规范。

关于javascript - framework7 防止缓存页面数据,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/38413716/

相关文章:

javascript - Canvas - 在较大的背景图像上叠加小图像,合并为单个 Canvas 像素数据

javascript - JS : How to dynamically insert text into a SPAN?

javascript - 单击事件未触发并溢出 : scroll

java - 无法更新安卓应用

php - 使用 PHP 将数组从 PHP 传递到 javascript

javascript 启动不当

HTML - 在新行中放置图像

javascript - Chrome 中的 CSS 延迟加载

html - 如何通过 ASP.NET MVC 中的 ViewData 将 html 传递到 View 中的页面?

javascript - 我们如何使用phonegap或javascript打开iPhone/android native 键盘