@lunora/container 1.0.0-alpha.92 → 1.0.0-alpha.94

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.
package/dist/bridge.d.mts CHANGED
@@ -1,3 +1,18 @@
1
+ /**
2
+ * `@lunora/container/bridge` — the container→Lunora client.
3
+ *
4
+ * Container code (any JS runtime — Node, Bun, Deno) uses this to call back
5
+ * into the app's Lunora functions over the Worker's HTTP RPC endpoint
6
+ * (`POST /_lunora/rpc`), so a container can read/write app state through the
7
+ * same queries/mutations/actions the browser uses instead of reaching into a
8
+ * database directly.
9
+ *
10
+ * Pure `fetch` over the documented wire contract — no Cloudflare imports — so
11
+ * it runs in any container and is unit-testable with an injected `fetch`. The
12
+ * transport is the public RPC endpoint authenticated with a bearer token your
13
+ * Worker's `resolveIdentity` recognizes (forward it as a container `secret`).
14
+ * Non-JS containers can implement the same one-line contract directly.
15
+ */
1
16
  import { LunoraError } from '@lunora/errors';
2
17
  /**
3
18
  * A `fetch` implementation — defaults to the runtime global.
package/dist/bridge.d.ts CHANGED
@@ -1,3 +1,18 @@
1
+ /**
2
+ * `@lunora/container/bridge` — the container→Lunora client.
3
+ *
4
+ * Container code (any JS runtime — Node, Bun, Deno) uses this to call back
5
+ * into the app's Lunora functions over the Worker's HTTP RPC endpoint
6
+ * (`POST /_lunora/rpc`), so a container can read/write app state through the
7
+ * same queries/mutations/actions the browser uses instead of reaching into a
8
+ * database directly.
9
+ *
10
+ * Pure `fetch` over the documented wire contract — no Cloudflare imports — so
11
+ * it runs in any container and is unit-testable with an injected `fetch`. The
12
+ * transport is the public RPC endpoint authenticated with a bearer token your
13
+ * Worker's `resolveIdentity` recognizes (forward it as a container `secret`).
14
+ * Non-JS containers can implement the same one-line contract directly.
15
+ */
1
16
  import { LunoraError } from '@lunora/errors';
2
17
  /**
3
18
  * A `fetch` implementation — defaults to the runtime global.
@@ -1,3 +1,11 @@
1
+ /**
2
+ * `@lunora/container/do` — the workerd-only half of the package.
3
+ *
4
+ * `@cloudflare/containers` imports `cloudflare:workers` at module scope, so
5
+ * anything touching it lives behind this subpath: the package root stays
6
+ * importable from Node tooling (codegen, config, app unit tests) while the
7
+ * generated `_generated/containers.ts` imports the base class from here.
8
+ */
1
9
  import { d as ContainerRuntimeInstanceType, C as ContainerDefinition, D as DurableObjectJurisdiction, b as ContainerSnapshot, e as ContainerSpawnRequest } from "../packem_shared/jurisdiction.d-BwpauCoI.mjs";
2
10
  import { DurableObject, WorkerEntrypoint, RpcTarget } from 'cloudflare:workers';
3
11
  /**
@@ -1,3 +1,11 @@
1
+ /**
2
+ * `@lunora/container/do` — the workerd-only half of the package.
3
+ *
4
+ * `@cloudflare/containers` imports `cloudflare:workers` at module scope, so
5
+ * anything touching it lives behind this subpath: the package root stays
6
+ * importable from Node tooling (codegen, config, app unit tests) while the
7
+ * generated `_generated/containers.ts` imports the base class from here.
8
+ */
1
9
  import { d as ContainerRuntimeInstanceType, C as ContainerDefinition, D as DurableObjectJurisdiction, b as ContainerSnapshot, e as ContainerSpawnRequest } from "../packem_shared/jurisdiction.d-BwpauCoI.js";
2
10
  import { DurableObject, WorkerEntrypoint, RpcTarget } from 'cloudflare:workers';
3
11
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lunora/container",
3
- "version": "1.0.0-alpha.92",
3
+ "version": "1.0.0-alpha.94",
4
4
  "description": "Cloudflare Containers for Lunora: defineContainer, generated Container DO classes, and the ctx.containers action surface",
5
5
  "keywords": [
6
6
  "cloudflare",