-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
docs(js): Review and update Express Quick Start guide #14218
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
1 Skipped Deployment
|
Bundle ReportChanges will decrease total bundle size by 1.47kB (-0.01%) ⬇️. This is within the configured threshold ✅ Detailed changes
Affected Assets, Files, and Routes:view changes for bundle: sentry-docs-client-array-pushAssets Changed:
view changes for bundle: sentry-docs-server-cjsAssets Changed:
|
```javascript | ||
app.get("/debug-sentry", async function mainHandler(req, res) { | ||
const customSpan = Sentry.startSpan({ | ||
op: "test", | ||
name: "My First Test Transaction", | ||
}); | ||
|
||
try { | ||
await new Promise((resolve) => setTimeout(resolve, 100)); // Wait for 100ms | ||
throw new Error("My first Sentry error!"); | ||
} finally { | ||
customSpan.end(); | ||
} | ||
}); | ||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please use the API as described in https://docs.sentry.io/platforms/javascript/guides/express/tracing/instrumentation/
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@chargome I've updated the snippet -- please take a look :)
…ick-start/review-express
DESCRIBE YOUR PR
Reviewed and updated the Express Quick Start guide.
IS YOUR CHANGE URGENT?
Help us prioritize incoming PRs by letting us know when the change needs to go live.
SLA
Thanks in advance for your help!
PRE-MERGE CHECKLIST
Make sure you've checked the following before merging your changes:
EXTRA RESOURCES