-
Notifications
You must be signed in to change notification settings - Fork 50
Closed
Labels
Description
Is there an existing issue for this?
- I have checked for existing issues https://github.com/getsentry/sentry-javascript/issues
- I have reviewed the documentation https://docs.sentry.io/
- I am using the latest SDK release https://github.com/getsentry/sentry-javascript/releases
How do you use Sentry?
Sentry Saas (sentry.io)
Which SDK are you using?
@sentry/react
SDK Version
7.51.0
Framework Version
No response
Link to Sentry event
No response
SDK Setup
No response
Steps to Reproduce
Add Sentry's vite plugin/suggested flow to this example:
https://github.com/vite-pwa/vite-plugin-pwa/tree/main/examples/react-router/src
Expected Result
The expected result is that it works. Can we remove this from the dang github issue template?
Actual Result
The registerSW.js that appears generated ends up with an invalid statement injected from Sentry:
if ('serviceWorker'in navigator)
navigator.serviceWorker.register('/dev-sw.js?dev-sw', {
scope: '/',
type: 'classic'
});
import "/@fs/home/dcramer/src/peated/node_modules/@sentry/bundler-plugin-core/sentry-release-injection-file.js?v=ca9b2c4c";
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjpudWxsLCJzb3VyY2VzIjpbbnVsbF0sInNvdXJjZXNDb250ZW50IjpbbnVsbF0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBIn0=