How to turn off caching on Firefox?

后端 未结 17 733
失恋的感觉
失恋的感觉 2020-11-28 00:26

During development I have to \"clear cache\" in Firefox all the time in order to make it use the latest version of JavaScript files.

Is there some kind of setting (a

相关标签:
17条回答
  • 2020-11-28 01:00

    Enter "about:config" into the Firefox address bar and set:

    browser.cache.disk.enable = false
    browser.cache.memory.enable = false
    

    If developing locally, or using HTML5's new manifest attribute you may have to also set the following in about:config -

    browser.cache.offline.enable = false
    
    0 讨论(0)
  • 2020-11-28 01:01

    Firefox 48 Developer Tools

    Allows you to turn off cache only when toolbox is open, which is perfect for web development:

    • F12
    • gearbox on right upper corner
    • scroll down top Advanced settings
    • check "Disable Cache (when toolbox is open)"

    https://stackoverflow.com/a/27397425/895245 has similar content, but positioning changed a bit since.

    0 讨论(0)
  • 2020-11-28 01:01

    Best strategy is to design your site to build a unique URL to your JS files, that gets reset every time there is a change. That way it caches when there has been no change, but imediately reloads when any change occurs.

    You'd need to adjust for your specific environment tools, but if you are using PHP/Apache, here's a great solution for both you, and the end-users.

    http://verens.com/archives/2008/04/09/javascript-cache-problem-solved/

    0 讨论(0)
  • 2020-11-28 01:02

    There is no specific option to disable caching only for JavaScript, you will have to disable caching entirely.

    FireBug has an option to disable the browser cache on the Network tab's drop down menu.

    0 讨论(0)
  • 2020-11-28 01:04

    On the same page you want to disable the caching do this : FYI: the version am working on is 30.0

    You can :

    open webdeveloper toolbar open web developer

    and pick disable cache

    After that it will reload page from its own (you are on) and every thing is recached and any furthure request are recahed every time too and you may keep the web developer open always to keep an eye and make sure its always on (check).

    0 讨论(0)
  • 2020-11-28 01:05

    I use CTRL-SHIFT-DELETE which activates the privacy feature, allowing you to clear your cache, reset cookies, etc, all at once. You can even configure it so that it just DOES it, instead of popping up a dialog box asking you to confirm.

    0 讨论(0)
提交回复
热议问题