After deployment, not all assets were updated on the main page

I have a project connected to github with links to *.pages.dev and the main domain after the last commit *.pages.dev was updated correctly on the main domain, only the html file (the js remains old) deleted the local cache I deleted the old deployments already tried to restart the deployment several times watched from different devices what can be done so that all asserts files are updated to the latest version?
10 Replies
Vlad
VladOP•11mo ago
Production branch: main Automatic deployments: Enabled Preview Branches included: All non-Production branches Automatic deployments: Enabled Build caching: Disabled
remnote_martin
remnote_martin•11mo ago
Purging the clouflare cache on the domain has fixed this for us in the past
Vlad
VladOP•11mo ago
Oh yes, really Domain > Caching > Configuration > Purge Cache And after 30 seconds there was already the latest version of the file thank you
Chaika
Chaika•11mo ago
CF by default caches certain extensions like css/js, which makes logical sense except with Pages which has its own cache layer under it. https://developers.cloudflare.com/cache/concepts/default-cache-behavior/
Chaika
Chaika•11mo ago
You can make a cache rule to disable that cache
No description
Chaika
Chaika•11mo ago
Cache Rules are under Caching -> Cache Rules, or magic link: https://dash.cloudflare.com/?to=/:account/:zone/caching/cache-rules/new otherwise you need to clear it every time or wait it out
Vlad
VladOP•11mo ago
this is very helpful for me, thank you
z0rrn
z0rrn•11mo ago
Is my site then slower or are all pages assets deployed to all servers?
remnote_martin
remnote_martin•10mo ago
I don't understand why Pages doesn't automatically update the cloudflare cache 🤔
Chaika
Chaika•10mo ago
wouldn't be too easy I imagine, espec with pages projects having up to 500+ custom domains Pages uses KV which has its own build in cache https://developers.cloudflare.com/kv/reference/how-kv-works/ Your html and such was already not being cached by your zone/hitting kv cache, so shouldn't be a big difference. Zone cache can be a bit faster since the pages worker doesn't run but it's minor
Want results from more Discord servers?
Add your server