Clarify caching difference between Cloudflare Workers with Static Assets and Cloudflare Pages advanced mode #20445
Labels
content:edit
Request for content edits
documentation
Documentation edits
product:pages
product:workers
Related to Workers product
Existing documentation URL(s)
What changes are you suggesting?
I have found a difference betwee Cloudflare Workers with Static Assets and Cloudflare Pages advanced mode function that I think is not well documented. Cloudflare Pages advanced mode functions run AFTER the Cache Rules while Cloudflare Workers run BEFORE the Cache Rules.
The docs for Cloudflare Pages allude to this - https://developers.cloudflare.com/pages/configuration/serving-pages/#caching-and-performance
With Cloudflare Pages advanced mode functions, I can do SWR with Cache Rules.
With Cloudflare Workers, this is not possible. My worker always executes.
It would be nice if this was more clearly documented. It would be really nice if there was an option for Cloudflare Workers to execute after Cache Rules. Then you could deprecate advanced mode for Cloudflare Pages and direct everyone to Cloudflare Workers with Static Assets.
Thank you.
Additional information
No response
The text was updated successfully, but these errors were encountered: