Skip to content

Conversation

@lforst
Copy link
Contributor

@lforst lforst commented Apr 10, 2024

Fixes #6423

Adds functionality on the browser for the root option.

@github-actions
Copy link
Contributor

github-actions bot commented Apr 10, 2024

size-limit report 📦

Path Size
@sentry/browser 22.09 KB (0%)
@sentry/browser (incl. Tracing) 31.78 KB (0%)
@sentry/browser (incl. Tracing, Replay) 66.99 KB (0%)
@sentry/browser (incl. Tracing, Replay) - with treeshaking flags 60.58 KB (0%)
@sentry/browser (incl. Tracing, Replay with Canvas) 70.83 KB (0%)
@sentry/browser (incl. Tracing, Replay, Feedback) 80.69 KB (0%)
@sentry/browser (incl. Feedback) 35.64 KB (0%)
@sentry/browser (incl. Feedback, Feedback Modal) 35.65 KB (0%)
@sentry/browser (incl. Feedback, Feedback Modal, Feedback Screenshot) 35.66 KB (0%)
@sentry/browser (incl. sendFeedback) 26.89 KB (0%)
@sentry/react 24.78 KB (0%)
@sentry/react (incl. Tracing) 34.7 KB (0%)
@sentry/vue 25.64 KB (0%)
@sentry/vue (incl. Tracing) 33.5 KB (0%)
@sentry/svelte 22.22 KB (0%)
CDN Bundle 24.21 KB (0%)
CDN Bundle (incl. Tracing) 32.83 KB (0%)
CDN Bundle (incl. Tracing, Replay) 66.55 KB (0%)
CDN Bundle (incl. Tracing, Replay, Feedback) 80.56 KB (0%)
CDN Bundle - uncompressed 72.06 KB (0%)
CDN Bundle (incl. Tracing) - uncompressed 98.34 KB (0%)
CDN Bundle (incl. Tracing, Replay) - uncompressed 207.73 KB (0%)
@sentry/nextjs (client) 33.95 KB (+0.22% 🔺)
@sentry/sveltekit (client) 32.3 KB (0%)
@sentry/node 120.15 KB (0%)

@lforst lforst marked this pull request as ready for review April 11, 2024 06:39
@lforst lforst requested review from AbhiPrasad, mydea and s1gr1d April 11, 2024 06:39
const root = options.root;
const prefix = options.prefix || 'app:///';

const iteratee: StackFrameIteratee =
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I re-shuffled the code a bit so we can test it more easily

}
return frame;
});
const isBrowser = 'window' in GLOBAL_OBJ && GLOBAL_OBJ.window !== undefined;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

l: Can we just compress this to !!GLOBAL_OBJ.window? I think that should be safe enough..?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typescript sadness but yeah

@lforst lforst merged commit ac803e9 into develop Apr 11, 2024
@lforst lforst deleted the lforst-rewrite-frames-new-root-behaviour branch April 11, 2024 11:13
cadesalaberry pushed a commit to cadesalaberry/sentry-javascript that referenced this pull request Apr 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

RewriteFrames not functional in browser environments

3 participants