astro-cdn-loader
v0.0.0
Published
An Astro integration to load packages from a CDN like jsDelivr or unpkg.
Maintainers
Readme
astro-cdn-loader
An Astro integration to load packages from a CDN like jsDelivr or unpkg.
Usage
Prerequisites
- Astro >= 5.0.0
Installation
Install the integration automatically using the Astro CLI:
pnpm astro add astro-cdn-loadernpx astro add astro-cdn-loaderyarn astro add astro-cdn-loaderOr install it manually:
Install the required dependencies
pnpm add astro-cdn-loadernpm install astro-cdn-loaderyarn add astro-cdn-loaderAdd the integration to your astro config
+import CdnLoader from "astro-cdn-loader"; export default defineConfig({ integrations: [ + CdnLoader(), ], });
Configuration
TODO:configuration
Contributing
This package is structured as a monorepo:
playgroundcontains code for testing the packagepackagecontains the actual package
Install dependencies using pnpm:
pnpm i --frozen-lockfileStart the playground and package watcher:
pnpm devYou 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 anmoti.
Acknowledgements
- Created using astro-integration-template.
- Inspired by vite-plugin-cdn-import.
