@varlock/cloudflare-integration 0.0.1 → 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,29 @@
1
+ /**
2
+ * Varlock SvelteKit + Cloudflare Vite plugin.
3
+ *
4
+ * For SvelteKit projects deploying to Cloudflare Workers via
5
+ * `@sveltejs/adapter-cloudflare`. Unlike `varlockCloudflareVitePlugin`, this
6
+ * does NOT include `@cloudflare/vite-plugin` (which doesn't currently support
7
+ * SvelteKit — see https://github.com/cloudflare/workers-sdk/issues/8922).
8
+ *
9
+ * Injects the `cloudflare:workers` runtime env-loader into SvelteKit's SSR
10
+ * entry, which is picked up by adapter-cloudflare's generated `_worker.js`.
11
+ * Non-sensitive vars and the `__VARLOCK_ENV` secret should still be uploaded
12
+ * via `varlock-wrangler deploy`.
13
+ *
14
+ * @example
15
+ * ```ts
16
+ * import { sveltekit } from '@sveltejs/kit/vite';
17
+ * import { varlockSvelteKitCloudflarePlugin } from '@varlock/cloudflare-integration/sveltekit';
18
+ *
19
+ * export default defineConfig({
20
+ * plugins: [
21
+ * varlockSvelteKitCloudflarePlugin(),
22
+ * sveltekit(),
23
+ * ],
24
+ * });
25
+ * ```
26
+ */
27
+ declare function varlockSvelteKitCloudflarePlugin(): Array<any>;
28
+
29
+ export { varlockSvelteKitCloudflarePlugin };