Skip to content

False positive pushstate warnings with SvelteKit #13823

Open

Description

Is there an existing issue for this?

How do you use Sentry?

Sentry Saas (sentry.io)

Which SDK are you using?

@sentry/sveltekit

SDK Version

8.32.0

Framework Version

sveltekit 2.5.28

Link to Sentry event

No response

Reproduction Example/SDK Setup

sveltejs/kit#12177

Steps to Reproduce

Just start a sveltekit app with sentry and on first page load you will see the warning.

seems like initiating here // node_modules/@sentry-internal/browser-utils/build/esm/instrument/history.js

[Warning] Avoid using history.pushState(...)andhistory.replaceState(...)as these will conflict with SvelteKit's router. Use thepushStateandreplaceStateimports from$app/navigation instead. (client.js, line xxx)

Expected Result

No wanning while using svelte app navigation.

Actual Result

Image

[Warning] Avoid using history.pushState(...)andhistory.replaceState(...)as these will conflict with SvelteKit's router. Use thepushStateandreplaceStateimports from$app/navigation instead. (client.js, line xxx)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    Package: sveltekitIssues related to the Sentry SvelteKit SDK

    Type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions