Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions website/src/content/docs/actors/inspector-tabs.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ Each entry in `inspector.tabs[]` is either a **custom tab** or a

### Custom tab

```ts
```ts @nocheck
{
id: string, // URL-safe id: /^[A-Za-z0-9_-]+$/
label: string, // Shown in the tab strip
Expand All @@ -125,7 +125,7 @@ Each entry in `inspector.tabs[]` is either a **custom tab** or a

### Hide a built-in tab

```ts
```ts @nocheck
{
id: "workflow" | "database" | "state" | "queue" | "connections" | "console",
hidden: true,
Expand Down Expand Up @@ -154,7 +154,7 @@ The dashboard sends an `init` message on load and again whenever the
inspector token rotates. Always overwrite the cached token when it
arrives.

```ts
```ts @nocheck
{
type: "init",
v: 1,
Expand All @@ -168,23 +168,23 @@ arrives.
For tabs with sub-views, the dashboard also sends `set-active-tab`
when the user switches:

```ts
```ts @nocheck
{ type: "set-active-tab", v: 1, tab: string }
```

### From the tab

Send `ready` once your message listener is registered:

```ts
```ts @nocheck
{ type: "ready", v: 1 }
```

If a fetch returns 401, the token has rotated. Ask the dashboard for a
fresh one and wait for the next `init` — don't retry with the stale
token:

```ts
```ts @nocheck
{ type: "token-refresh-needed", v: 1 }
```

Expand Down
Loading