@beignet/devtools 0.0.6 → 0.0.8
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/CHANGELOG.md +8 -0
- package/README.md +37 -18
- package/dist/ui-html.generated.d.ts +2 -0
- package/dist/ui-html.generated.d.ts.map +1 -0
- package/dist/ui-html.generated.js +3 -0
- package/dist/ui-html.generated.js.map +1 -0
- package/dist/ui.d.ts +0 -5
- package/dist/ui.d.ts.map +1 -1
- package/dist/ui.js +19 -927
- package/dist/ui.js.map +1 -1
- package/package.json +23 -4
- package/src/ui-html.generated.ts +3 -0
- package/src/ui.ts +23 -926
- package/src/ui-model.ts +0 -1233
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @beignet/devtools
|
|
2
2
|
|
|
3
|
+
## 0.0.8
|
|
4
|
+
|
|
5
|
+
## 0.0.7
|
|
6
|
+
|
|
7
|
+
### Patch Changes
|
|
8
|
+
|
|
9
|
+
- 3537da0: Rewrite the devtools dashboard as a shadcn-based UI with dark mode, sidebar navigation grouped by section, a request lifecycle waterfall, owner-grouped errors, focus-panel metrics, and a JSON viewer with syntax highlighting. The route contract is unchanged and the package adds zero new runtime dependencies — the dashboard compiles into a single self-contained HTML file at package build time.
|
|
10
|
+
|
|
3
11
|
## 0.0.6
|
|
4
12
|
|
|
5
13
|
## 0.0.5
|
package/README.md
CHANGED
|
@@ -64,27 +64,37 @@ export const { GET, POST } = createDevtoolsRoute(server.ports.devtools, {
|
|
|
64
64
|
Open `/api/devtools`.
|
|
65
65
|
|
|
66
66
|
The dashboard connects to the event stream with Server-Sent Events and falls
|
|
67
|
-
back to polling when `EventSource` is unavailable.
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
`
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
67
|
+
back to polling when `EventSource` is unavailable. A sidebar groups views by
|
|
68
|
+
section — Overview, HTTP, Application, Infrastructure, and Operations — with
|
|
69
|
+
live event-count badges per view, plus dynamic views for enabled custom
|
|
70
|
+
watchers. The header shows clickable stats (events, requests, errors, use
|
|
71
|
+
cases), live connection status, Pause/Resume, and Clear. Pausing buffers
|
|
72
|
+
incoming events and reveals them on resume.
|
|
73
|
+
|
|
74
|
+
The dashboard follows the system color scheme and includes a manual
|
|
75
|
+
light/dark/system toggle persisted in `localStorage`. The theme matches the
|
|
76
|
+
shadcn look of generated Beignet starter apps.
|
|
77
|
+
|
|
78
|
+
Request rows expand into an end-to-end lifecycle view for events that share
|
|
79
|
+
the same `traceId` or `requestId`. The detail renders a lifecycle waterfall:
|
|
80
|
+
correlated spans drawn as relative timing bars (durations are measured at
|
|
81
|
+
completion), alongside overview facts such as route match, contract name,
|
|
82
|
+
request ID, trace ID, method, path, status, duration, and response ownership,
|
|
83
|
+
a redaction note, correlated activity grouped by category, and the raw JSON.
|
|
84
|
+
|
|
85
|
+
Press `/` to focus search, which matches event summaries, paths, messages,
|
|
86
|
+
names, watchers, IDs, and details. Method, status, and watcher filters narrow
|
|
87
|
+
noisy timelines. Timeline rows lead with the human-readable summary, and IDs
|
|
88
|
+
truncate to copy-on-click chips. The JSON detail viewer renders syntax
|
|
89
|
+
highlighting, collapsible nodes, and a copy button.
|
|
90
|
+
|
|
91
|
+
The errors view groups failures by owner: route, framework, provider, job,
|
|
82
92
|
schedule, outbox, client-side, devtools, or unknown. Each row shows the
|
|
83
93
|
message, owner, related route/status, request ID, trace ID, and nearby
|
|
84
94
|
correlated events so you can see whether a failure belongs to application code,
|
|
85
95
|
the framework boundary, provider work, or background execution.
|
|
86
96
|
|
|
87
|
-
|
|
97
|
+
Focus panels render subsystem metrics, row summaries, and drill-down fields
|
|
88
98
|
for each Beignet workflow primitive. Database shows query counts, failures,
|
|
89
99
|
inferred table names, redaction status, provider name, port, parameter count,
|
|
90
100
|
and request/trace IDs when the runtime can preserve active request context.
|
|
@@ -200,8 +210,8 @@ Disabled watchers do not store matching events. The installed watcher metadata
|
|
|
200
210
|
is available through `ctx.ports.devtools.getWatchers()` and the dashboard API.
|
|
201
211
|
|
|
202
212
|
Custom integrations can also register watcher metadata for their own event
|
|
203
|
-
types. Custom watcher
|
|
204
|
-
events:
|
|
213
|
+
types. Custom watcher views appear in the dashboard sidebar when they own
|
|
214
|
+
`custom` events:
|
|
205
215
|
|
|
206
216
|
```typescript
|
|
207
217
|
createDevtoolsProvider({
|
|
@@ -506,6 +516,15 @@ code does not need null checks.
|
|
|
506
516
|
Devtools can contain sensitive request, error, and domain data. Keep it on local
|
|
507
517
|
development routes unless you intentionally add authentication and redaction.
|
|
508
518
|
|
|
519
|
+
## Development
|
|
520
|
+
|
|
521
|
+
The dashboard UI is a React app in `ui/`. `bun run build:ui` compiles it into
|
|
522
|
+
one self-contained HTML file and embeds it in the package as a generated module
|
|
523
|
+
(`src/ui-html.generated.ts`, gitignored); `bun run build` runs `build:ui` and
|
|
524
|
+
then the TypeScript build. From a fresh clone, run `bun run build` once before
|
|
525
|
+
running this package's tests directly — the root `bun run test` handles that
|
|
526
|
+
ordering through turbo.
|
|
527
|
+
|
|
509
528
|
## License
|
|
510
529
|
|
|
511
530
|
MIT
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ui-html.generated.d.ts","sourceRoot":"","sources":["../src/ui-html.generated.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,uBAAuB,EAAE,MACqprc,CAAC"}
|