1.0.0 • Published 4 months ago

astro-integration-cloudflare-pages-headers v1.0.0

Weekly downloads
-
License
MIT
Repository
-
Last release
4 months ago

astro-integration-cloudflare-pages-headers

This is an Astro integration that takes the headers provided to the Astro config object and applies them to a Cloudflare Pages deployment _headers file during build.

Usage

Prerequisites

TODO:

Installation

Install the integration automatically using the Astro CLI:

pnpm astro add astro-integration-cloudflare-pages-headers
npx astro add astro-integration-cloudflare-pages-headers
yarn astro add astro-integration-cloudflare-pages-headers

Or install it manually:

  1. Install the required dependencies
pnpm add astro-integration-cloudflare-pages-headers
npm install astro-integration-cloudflare-pages-headers
yarn add astro-integration-cloudflare-pages-headers
  1. Add the integration to your astro config
+import integration from "astro-integration-cloudflare-pages-headers";

export default defineConfig({
  integrations: [
+    integration(),
  ],
});

Configuration

TODO:configuration

Contributing

This package is structured as a monorepo:

  • playground contains code for testing the package
  • package contains the actual package

Install dependencies using pnpm:

pnpm i --frozen-lockfile

Start the playground and package watcher:

pnpm dev

You can now edit files in package. Please note that making changes to those files may require restarting the playground dev server.

Licensing

MIT Licensed. Made with ❤️ by martinsilha.

Acknowledgements