brewedbits.dev

Personal blog with guides and news on selfhosting, Linux and AI, from the Netherlands

nextDash nextdash --aboutYour bookmarks. Your terminal. checks your links knows your Docker host one container, no cloudLive demo →nextdash.cc ↗

Tip: Disable cache in DevTools makes every reload fetch files from the server

Devtools
~/tips/tip-devtools-disable-cache-checkbox

Network panel > Disable cache

Stop old CSS and scripts from confusing you while you work on a site.

You change a stylesheet, reload, and nothing happens. Before I blame the code I make sure the browser is not showing me yesterday’s file.

Open DevTools and tick the box:

Network panel > Disable cache

As long as DevTools is open, requests skip the browser cache, so each reload gets the files from the server again. It also shows you what a first time visitor downloads, which is a nice reality check for page weight.

If you want it while working in another panel, the same checkbox lives in the Network conditions drawer:

Ctrl+Shift+P > Show Network conditions > Disable cache

It only covers your own browser’s cache. A CDN, a reverse proxy or a caching plugin in front of the site can still hand out the old copy, and then the box changes nothing. Look at the response headers to see who answered. A service worker can also serve files on its own.

And remember to untick it when you measure how fast a repeat visit is, or you will think your caching rules are broken when you switched them off yourself.

Further reading: Chrome DevTools: network features reference

Going deeper: Guide: your Unraid cache is full and Docker stopped, how to find out why and fix it

More Devtools tips Clear site data for one site from Chrome DevTools user.id === 42 $x(path [, startNode]) @media (prefers-color-scheme: dark) { queryObjects(Promise) All Devtools tips (22) All topics

Link