https://github.com/subtrace/sveltekit-demo
SvelteKit + Subtrace demo
https://github.com/subtrace/sveltekit-demo
Last synced: 17 days ago
JSON representation
SvelteKit + Subtrace demo
- Host: GitHub
- URL: https://github.com/subtrace/sveltekit-demo
- Owner: subtrace
- License: bsd-3-clause
- Created: 2025-02-16T00:16:13.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-12-24T22:09:35.000Z (3 months ago)
- Last Synced: 2025-12-26T11:57:01.823Z (3 months ago)
- Language: TypeScript
- Size: 28.3 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# SvelteKit + Subtrace
This repo shows how to add [Subtrace](https://subtrace.dev) to a sample SvelteKit app.
Subtrace connects your server to Chrome DevTools so that you can inspect the status,
headers, payload, and latency of each request.
Clone this repo, and download Subtrace on your machine:
```bash
curl -fSLO "https://subtrace.dev/download/$(uname -s)/$(uname -m)/subtrace" && chmod +x ./subtrace
```
Then get a `SUBTRACE_TOKEN` from the Subtrace [dashboard](https://subtrace.dev/dashboard)
for free and set it as an environment variable.
```bash
# get a tracer token for free at https://subtrace.dev/dashboard
export SUBTRACE_TOKEN=subt_...xxxxx
```
Start the SvelteKit app with Subtrace.
```bash
npm install
npm run build
./subtrace run -- npm run dev
```
That's it! You can now visit [localhost:5173](localhost:5173) and make requests
to the app that show up on the Subtrace dashboard in realtime:
https://github.com/user-attachments/assets/f4b7b3de-41e9-48ca-8707-cd6ac1868b3c