Skip to content

Commit 3fbe3d9

Browse files
authored
mention default entrypoint workaround (#22716)
1 parent ebbf863 commit 3fbe3d9

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

src/content/docs/workers/runtime-apis/rpc/typescript.mdx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,10 @@ For example, if your client Worker had bindings to a Worker in `../sum-worker/`
2828
}
2929
/>
3030

31+
:::note
32+
If your service binding targets a `WorkerEntrypoint` that is a default export, make sure you set `entrypoint: "default"` in your Wrangler config when you configure your service binding.
33+
:::
34+
3135
This will produce a `worker-configuration.d.ts` file that includes:
3236

3337
```ts title="worker-configuration.d.ts"

src/content/docs/workers/wrangler/commands.mdx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1985,6 +1985,7 @@ wrangler types [<PATH>] [OPTIONS]
19851985
SERVICE_BINDING: Service<import("../bound-worker/src/index").Entrypoint>;
19861986
}
19871987
```
1988+
- If your service binding targets a [`WorkerEntrypoint`](/workers/runtime-apis/bindings/service-bindings/rpc/) that is a default export, make sure you set `entrypoint: "default"` in your Wrangler config when you configure your service binding.
19881989

19891990
---
19901991

0 commit comments

Comments
 (0)