Skip to content

Compatibility issue with Sentry + Next.js #14

Description

@rnbrady

When using with Next.js 15, if Sentry is added to the project then rendering fails with Uncaught TypeError: Failed to construct 'HTMLElement': Please use the 'new' operator, this DOM object constructor cannot be called as a function.

The error can be resolved by upgrading Stencil. PR to follow shortly.

See rnbrady/qrcode-sentry-issue for reproduction. Before vs after adding Sentry:

Screenshot 2025-01-07 at 14 06 39

The issue seems to be specific to Next.js or React as I'm unable to reproduce it by adding Sentry to the vanilla HTML + Js demo pages.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions