Skip to content

Fix mmc release v31#2876

Merged
alexandratran merged 6 commits into
mainfrom
fix-mmc-release-v31
Apr 22, 2026
Merged

Fix mmc release v31#2876
alexandratran merged 6 commits into
mainfrom
fix-mmc-release-v31

Conversation

@shahbaz17

@shahbaz17 shahbaz17 commented Apr 22, 2026

Copy link
Copy Markdown
Member

Description

Document breaking API changes: connectAndSign and connectWith now return objects ({ accounts, chainId, signature }) and ({ accounts, chainId, result }) respectively. Updated examples across quickstart, guides, and reference to destructure these fields and log accounts/chainId alongside results, and added breaking-change notes. Also adjusted the EVM client status type name to ConnectEvmStatus in the reference and clarified CSP troubleshooting guidance for the QR-code fox SVG (img-src data: and older-version fallbacks).

Issue(s) fixed

Fixes #

Preview

Checklist

  • If this PR updates or adds documentation content that changes or adds technical meaning, it has received an approval from an engineer or DevRel from the relevant team.
  • If this PR updates or adds documentation content, it has received an approval from a technical writer.

External contributor checklist

  • I've read the contribution guidelines.
  • I've created a new issue (or assigned myself to an existing issue) describing what this PR addresses.

Note

Low Risk
Documentation-only changes; main risk is confusing developers if the updated return shapes/CSP guidance are incorrect.

Overview
Updates MetaMask Connect EVM docs to reflect breaking return-shape changes: connectAndSign now returns { accounts, chainId, signature } and connectWith returns { accounts, chainId, result }, and all affected examples/event-handler snippets are updated to destructure and log the new fields.

Clarifies related documentation details, including renaming the documented client status type to ConnectEvmStatus, tightening CSP guidance for QR rendering (require data: in img-src rather than connect-src), and updating the Linea Sepolia bridge link.

Reviewed by Cursor Bugbot for commit bbb99fd. Bugbot is set up for automated code reviews on this repo. Configure here.

shahbaz17 and others added 4 commits April 20, 2026 21:08
Add a new troubleshooting 'Cause C' that explains how a strict Content Security Policy can prevent the MetaMask QR code from rendering (the fox SVG is embedded as a data: URI and materialized via a fetch-style call). The entry documents the console error, outlines the required CSP directives (allow data: in connect-src/img-src, include mm-sdk relay and analytics origins, and style-src 'unsafe-inline'), provides a minimal meta-tag example, and links to the connect-monorepo CSP reference.
Document breaking API changes: connectAndSign and connectWith now return objects ({ accounts, chainId, signature }) and ({ accounts, chainId, result }) respectively. Updated examples across quickstart, guides, and reference to destructure these fields and log accounts/chainId alongside results, and added breaking-change notes. Also adjusted the EVM client status type name to ConnectEvmStatus in the reference and clarified CSP troubleshooting guidance for the QR-code fox SVG (img-src data: and older-version fallbacks).
@shahbaz17 shahbaz17 requested review from a team as code owners April 22, 2026 15:41
@vercel

vercel Bot commented Apr 22, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
metamask-docs Ready Ready Preview, Comment Apr 22, 2026 4:04pm

Request Review

Update wording in EVM guides and reference to clarify that connectAndSign and connectWith now return objects and callers should read `.signature` and `.result` from the returned object (rather than implying destructuring). Minor punctuation/phrasing tweaks in migrate-from-sdk guide and methods reference for clearer guidance.
@alexandratran alexandratran merged commit 5bc38bd into main Apr 22, 2026
19 checks passed
@alexandratran alexandratran deleted the fix-mmc-release-v31 branch April 22, 2026 16:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants