getsentry / sentry-javascript

Official Sentry SDKs for JavaScript
https://sentry.io
MIT License
7.76k stars 1.52k forks source link

Improve Session Replay integration with server rendered HTML pages #9490

Open bruno-garcia opened 8 months ago

bruno-garcia commented 8 months ago

We're working on onboarding for backend project to include browser support. Similar to how we have NextJS, Remix, we want to onboarding for Laravel, ASP.NET, Django, Express, Spring, etc to include a snippet to be added to their html template. Enabling an experience to a single framework such as NextJS:

I was talking to @mydea and a few ideas came up:

Also:

mydea commented 7 months ago

ref: https://github.com/getsentry/sentry-javascript/issues/9468

bruno-garcia commented 7 months ago

Set to p1 because we're improving onboarding for MPA this quarter

bruno-garcia commented 7 months ago

Realistically unlikely we'll tackle this in the next 2 months

souredoutlook commented 5 months ago

Something I think we can tackle now without adding features is maybe making a guide with Laravel (or similar) about how to wring the most out of Replay by re-throwing back end errors on the front end or cooking the baggage headers to get the traces tab to conform with the framework.

ericemmrich commented 5 months ago

Something I think we can tackle now without adding features is maybe making a guide with Laravel (or similar) about how to wring the most out of Replay by re-throwing back end errors on the front end or cooking the baggage headers to get the traces tab to conform with the framework.

That would already help a lot - thank you in advance!

bruno-garcia commented 3 months ago

Came up on Twitter too:

image

mydea commented 1 month ago

Side note, you can try setting up replay with this config:

replayIntegration({
  minReplayDuration: 0,
  flushMinDelay: 200,
  flushMaxDelay: 250,
})

To get an experience that is better suited for MPAs!

mydea commented 3 weeks ago

See: https://www.notion.so/sentry/Replay-for-Server-Side-Rendered-SSR-Applications-a203bcba705a4823a9c5fbaed551c9af (internal document tracking possible implementation paths for this)