@varlock/cloudflare-integration
v0.0.1
Published
Cloudflare Workers integration for varlock - deploy secrets via wrangler and auto-configure Vite
Readme
@varlock/cloudflare-integration
This package helps you integrate varlock into a Cloudflare Workers project.
It provides:
- a Vite plugin (
varlockCloudflareVitePlugin) that wraps@cloudflare/vite-pluginwith automatic env var injection into miniflare bindings and Cloudflare's secret bindings at runtime - a
varlock-wranglerCLI binary — a drop-in replacement forwranglerthat injects env via named pipe in dev, uploads vars/secrets on deploy, and generates correct types - a standalone init module (
@varlock/cloudflare-integration/init) for non-Vite workers - validation of your env vars against your
.env.schema - type-generation and type-safe env var access with built-in docs
- redaction of sensitive values from logs
- leak prevention in responses
Compared to the base @varlock/vite-integration, this package avoids bundling secrets into your worker code. Instead, sensitive values are stored as Cloudflare secrets and non-sensitive values as Cloudflare vars.
See our docs site for complete installation and usage instructions.
