Skip to content

Feedback Modal: Missing Screenshot btn in production #12595

@zhiyan114

Description

@zhiyan114

Is there an existing issue for this?

How do you use Sentry?

Sentry Saas (sentry.io)

Which SDK are you using?

@sentry/react

SDK Version

8.10

Framework Version

18.2.0

Link to Sentry event

No response

SDK Setup

init({
  enabled: import.meta.env.PROD,
  dsn: import.meta.env["VITE_SENTRY_DSN"],
  integrations: [browserTracingIntegration(), feedbackIntegration({
    showEmail: false,
    showName: false,
    enableScreenshot: true,
  }), reactRouterV6BrowserTracingIntegration({
    useEffect: React.useEffect,
    createRoutesFromChildren,
    matchRoutes,
    useLocation,
    useNavigationType
  })],
  environment: import.meta.env.MODE,
  release: import.meta.env.VITE_commitHash,
})

Steps to Reproduce

  1. Setup a react vite project using their npx create tool
  2. Build the source with enableScreenshot set to true
  3. Publish it to a static host site on any domain name (other than localhost) that are NOT over secure connection (i.e. http)
  4. Open the feedback box

Expected Result

The "Add a screenshot" button should be showing up in production build

Actual Result

The button, will not show up.

Metadata

Metadata

Assignees

No one assigned

    Projects

    Status

    Waiting for: Product Owner

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions