I’m trying to enable server side rendering for a website. On the origin server, there are 3 configurations for each device (mobile, tablet or desktop) and I want to load these configurations using the ‘cf-device-type’ response header provided by Cloudflare, having cache enabled.
I want to ask you if it’s possible to make this work just by using Cloudflare page rules with cache everything option enabled.
I’m thinking that right now the content is not cached depending on device type because I want to load dynamic content. Please correct me if Cloudflare supports caching by device type, for dynamic content using page rules and help me to understand why the response is not being cached based on the device with ‘cache everything’ option enabled.
Maybe I can have an alternative by using Cloudflare workers, but then I don’t know if I will still have the ‘cf-device-type’ response header provided to origin server.