diff --git a/src/content/docs/durable-objects/examples/alarms-api.mdx b/src/content/docs/durable-objects/examples/alarms-api.mdx index e0453f1d2359181..31c2dea7ec57bc5 100644 --- a/src/content/docs/durable-objects/examples/alarms-api.mdx +++ b/src/content/docs/durable-objects/examples/alarms-api.mdx @@ -79,6 +79,7 @@ Finally, configure your Wrangler file to include a Durable Object [binding](/dur ```toml title="wrangler.toml" name = "durable-object-alarm" +main = "src/index.ts" [[durable_objects.bindings]] name = "BATCHER" diff --git a/src/content/docs/durable-objects/examples/build-a-counter.mdx b/src/content/docs/durable-objects/examples/build-a-counter.mdx index bea9ba2c49ee45b..0712e5e5bf3c2a8 100644 --- a/src/content/docs/durable-objects/examples/build-a-counter.mdx +++ b/src/content/docs/durable-objects/examples/build-a-counter.mdx @@ -171,6 +171,7 @@ Finally, configure your Wrangler file to include a Durable Object [binding](/dur ```toml title="wrangler.toml" name = "my-counter" +main = "src/index.ts" [[durable_objects.bindings]] name = "COUNTERS" diff --git a/src/content/docs/durable-objects/examples/build-a-rate-limiter.mdx b/src/content/docs/durable-objects/examples/build-a-rate-limiter.mdx index 400b7ab0e3cbf85..c56ec7ed9fd0ed2 100644 --- a/src/content/docs/durable-objects/examples/build-a-rate-limiter.mdx +++ b/src/content/docs/durable-objects/examples/build-a-rate-limiter.mdx @@ -283,6 +283,7 @@ Finally, configure your Wrangler file to include a Durable Object [binding](/dur ```toml title="wrangler.toml" name = "my-counter" +main = "src/index.ts" [[durable_objects.bindings]] name = "RATE_LIMITER" diff --git a/src/content/docs/durable-objects/examples/durable-object-in-memory-state.mdx b/src/content/docs/durable-objects/examples/durable-object-in-memory-state.mdx index 6b6e8ad18d931b2..9676fb5148ff784 100644 --- a/src/content/docs/durable-objects/examples/durable-object-in-memory-state.mdx +++ b/src/content/docs/durable-objects/examples/durable-object-in-memory-state.mdx @@ -73,6 +73,7 @@ Finally, configure your Wrangler file to include a Durable Object [binding](/dur ```toml title="wrangler.toml" name = "durable-object-in-memory-state" +main = "src/index.ts" [[durable_objects.bindings]] name = "LOCATION" diff --git a/src/content/docs/durable-objects/examples/durable-object-ttl.mdx b/src/content/docs/durable-objects/examples/durable-object-ttl.mdx index 2bd0a6d5448ff99..5dc650a7289d3f9 100644 --- a/src/content/docs/durable-objects/examples/durable-object-ttl.mdx +++ b/src/content/docs/durable-objects/examples/durable-object-ttl.mdx @@ -102,6 +102,7 @@ To test and deploy this example, configure your Wrangler file to include a Durab ```toml title="wrangler.toml" name = "durable-object-ttl" +main = "src/index.ts" [[durable_objects.bindings]] name = "MY_DURABLE_OBJECT" diff --git a/src/content/docs/durable-objects/examples/use-kv-from-durable-objects.mdx b/src/content/docs/durable-objects/examples/use-kv-from-durable-objects.mdx index 4ed2f79340b3ead..9db8ef9e710e8e5 100644 --- a/src/content/docs/durable-objects/examples/use-kv-from-durable-objects.mdx +++ b/src/content/docs/durable-objects/examples/use-kv-from-durable-objects.mdx @@ -27,6 +27,7 @@ Configure your Wrangler file as follows: ```toml name = "my-worker" +main = "src/index.ts" kv_namespaces = [ { binding = "YOUR_KV_NAMESPACE", id = "" } diff --git a/src/content/docs/durable-objects/examples/websocket-hibernation-server.mdx b/src/content/docs/durable-objects/examples/websocket-hibernation-server.mdx index 900b324f7ee351d..81d4996ab8ebcea 100644 --- a/src/content/docs/durable-objects/examples/websocket-hibernation-server.mdx +++ b/src/content/docs/durable-objects/examples/websocket-hibernation-server.mdx @@ -194,6 +194,7 @@ Finally, configure your Wrangler file to include a Durable Object [binding](/dur ```toml title="wrangler.toml" name = "websocket-hibernation-server" +main = "src/index.ts" [[durable_objects.bindings]] name = "WEBSOCKET_HIBERNATION_SERVER" diff --git a/src/content/docs/durable-objects/examples/websocket-server.mdx b/src/content/docs/durable-objects/examples/websocket-server.mdx index c4bae3392b8faa9..ecfaa5f86c9bc0c 100644 --- a/src/content/docs/durable-objects/examples/websocket-server.mdx +++ b/src/content/docs/durable-objects/examples/websocket-server.mdx @@ -198,6 +198,7 @@ Finally, configure your Wrangler file to include a Durable Object [binding](/dur ```toml title="wrangler.toml" name = "websocket-server" +main = "src/index.ts" [[durable_objects.bindings]] name = "WEBSOCKET_SERVER" diff --git a/src/content/docs/durable-objects/tutorials/build-a-seat-booking-app/index.mdx b/src/content/docs/durable-objects/tutorials/build-a-seat-booking-app/index.mdx index ac115b0a9e16de9..e33ebe391ef0f0b 100644 --- a/src/content/docs/durable-objects/tutorials/build-a-seat-booking-app/index.mdx +++ b/src/content/docs/durable-objects/tutorials/build-a-seat-booking-app/index.mdx @@ -282,7 +282,7 @@ npm run dev The application already has the binding for the Durable Objects class configured in the [Wrangler configuration file](/workers/wrangler/configuration/). If you update the name of the Durable Objects class in `src/index.ts`, make sure to also update the binding in the [Wrangler configuration file](/workers/wrangler/configuration/). -1. Update the binding to use the SQLite storage in Durable Objects. In the [Wrangler configuration file](/workers/wrangler/configuration/), replace `new_classes=["Flight"]` with `new_sqlite_classes=["Flight"]`, `name = "FLIGHT"` with `name = "FLIGHT"`, and `class_name = "MyDurableObject"` with `class_name = "Flight"`. your [Wrangler configuration file](/workers/wrangler/configuration/) should look like this: +1. Update the binding to use the SQLite storage in Durable Objects. In the [Wrangler configuration file](/workers/wrangler/configuration/), replace `new_classes=["Flight"]` with `new_sqlite_classes=["Flight"]`, `name = "FLIGHT"` with `name = "FLIGHT"`, and `class_name = "MyDurableObject"` with `class_name = "Flight"`. your [Wrangler configuration file](/workers/wrangler/configuration/) should look similar to this: