Major Changes
- #15435
957b9feThanks @rururux! - Changes the default image service fromcompiletocloudflare-binding. Image services options that resulted in broken images in development due to Node JS incompatiblities have now been updated to use the noop passthrough image service in dev mode. - (Cloudflare v13 and Astro6 upgrade guidance)
Minor Changes
-
#15435
957b9feThanks @rururux! - Adds support for configuring the image service as an object with separatebuildandruntimeoptionsIt is now possible to set both a build-time and runtime service independently. Currently,
'compile'is the only available build time option. The supported runtime options are'passthrough'(default) and'cloudflare-binding':import { defineConfig } from 'astro/config'; import cloudflare from '@astrojs/cloudflare'; export default defineConfig({ adapter: cloudflare({ imageService: { build: 'compile', runtime: 'cloudflare-binding' }, }), });
See the Cloudflare adapter
imageServicedocs for more information about configuring your image service. -
#15556
8fb329bThanks @florian-lefebvre! - Adds support for more@cloudflare/vite-pluginoptionsThe adapter now accepts the following options from Cloudflare's Vite plugin:
auxiliaryWorkersconfigPathinspectorPortpersistStateremoteBindingsexperimental.headersAndRedirectsDevModeSupport
For example, you can now set
inspectorPortto provide a custom port for debugging your Workers:// astro.config.mjs import { defineConfig } from 'astro/config'; import cloudflare from '@astrojs/cloudflare'; export default defineConfig({ adapter: cloudflare({ inspectorPort: 3456, }), });
Patch Changes
-
#15565
30cd6dbThanks @ematipico! - Fixes an issue where the use of theCodecomponent would result in an unexpected error. -
#15588
425ea16Thanks @rururux! - Fixes an issue whereesbuildwould throw a "Top-level return cannot be used inside an ECMAScript module" error during dependency scanning in certain environments. -
#15636
5ecd04cThanks @florian-lefebvre! - Adds an error when running on Stackblitz, sinceworkerddoesn't support it -
Updated dependencies []:
- @astrojs/underscore-redirects@1.0.0