Info on how to get asset content for pages functions

Hello all! I am trying to use cloudflare pages functions and followed the examples on the site here: https://developers.cloudflare.com/pages/functions/examples/cors-headers/ and I am trying to to modigy the asset content before I send it to the client. Am I able to do this? I can get the asset like so const asset = await context.env.ASSETS.fetch(url); but I havet figured out what to do with this this object to get the content of, for example, and html file
Cloudflare Docs
Adding CORS headers · Cloudflare Pages docs
This example is a snippet from our Cloudflare Pages Template repo.
1 Reply
clearwater4227
clearwater4227OP5mo ago
I figured it out
Want results from more Discord servers?
Add your server