diff options
author | 2022-12-29 13:30:34 -0400 | |
---|---|---|
committer | 2022-12-29 13:30:34 -0400 | |
commit | fc28b7cdc020143ef1413bf8dd773d08a1cb259c (patch) | |
tree | 07ead9cc45932018101a2eacbb1626a8f470c7f2 /packages/integrations | |
parent | 640de3c26fdc1a4d0272bc908ce822139d0cf73f (diff) | |
download | astro-fc28b7cdc020143ef1413bf8dd773d08a1cb259c.tar.gz astro-fc28b7cdc020143ef1413bf8dd773d08a1cb259c.tar.zst astro-fc28b7cdc020143ef1413bf8dd773d08a1cb259c.zip |
[docs] reflects updates to cloudflare: streams, env variables (#5694)
Diffstat (limited to 'packages/integrations')
-rw-r--r-- | packages/integrations/cloudflare/README.md | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/packages/integrations/cloudflare/README.md b/packages/integrations/cloudflare/README.md index 93d9a951d..723b5662c 100644 --- a/packages/integrations/cloudflare/README.md +++ b/packages/integrations/cloudflare/README.md @@ -81,19 +81,9 @@ getRuntime(Astro.request); Depending on your adapter mode (advanced = worker, directory = pages), the runtime object will look a little different due to differences in the Cloudflare API. -## Streams - -Some integrations such as [React](https://github.com/withastro/astro/tree/main/packages/integrations/react) rely on web streams. Currently Cloudflare Pages Functions require enabling a flag to support Streams. - -To do this: -- go to the Cloudflare Pages project -- click on Settings in the top bar, then Functions in the sidebar -- scroll down to Compatibility Flags, click Configure Production Compatibility Flags, and add `streams_enable_constructors` -- do this for both the Production Compatibility Flags and Preview Compatibility Flags - ## Environment Variables -As Cloudflare Pages Functions [provides environment variables per request](https://developers.cloudflare.com/pages/platform/functions/#adding-environment-variables-locally), you can only access private environment variables when a request has happened. Usually, this means moving environment variable access inside a function. +See Cloudflare's documentation for [working with environment variables](https://developers.cloudflare.com/pages/platform/functions/bindings/#environment-variables). ```js // pages/[id].json.js |