Wallet Connect works locally but not after deployment

Wallet connect working locally but Connect Wallet button doesn’t show after deployment. Console suggest CSP error, but have tried multiple fixes to no avail.

Hey @barrysutton! Welcome to the Community :smile:

Apologises, I’m not 100% sure on what you’re referring to when you say “Connect Wallet” button. Can you show me what it looks like locally?

I am experiencing an issue where the “Connect Wallet” button, which functions as part of my MetaMask integration, works perfectly in my local development environment but disappears after deployment to Vercel. Here’s the detailed breakdown:

  1. Expected Behavior:

• The “Connect Wallet” button should render on the deployed site, just as it does locally, and allow users to connect their MetaMask wallet.

  1. Actual Behavior:

• After deployment on Vercel, the button does not appear at all.

• The rest of the application is functioning correctly.

  1. Error Details:

• In the browser console, I encountered the following:

• A Content-Security-Policy (CSP) error indicating blocked usage of eval() in JavaScript, despite including unsafe-eval in my script-src directive.

• No other significant JavaScript or network errors.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.