Skip to content

[Chore] Add missing walletconnect exports to RN wallet exports #3444

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 21, 2024

Conversation

gregfromstl
Copy link
Member

@gregfromstl gregfromstl commented Jun 21, 2024

TL;DR

Adds wallet connect functions to react native.

What changed?

  • Added createWalletConnectClient, createWalletConnectSession, disconnectWalletConnectSession, getActiveWalletConnectSessions, and DefaultWalletConnectRequestHandlers exports to wallets.native.ts
  • Added type exports WalletConnectClient and WalletConnectSession to wallets.native.ts

How to test?

  1. Import the new functions and types in a React Native project.
  2. Test creating, managing, and disconnecting WalletConnect sessions.

Why make this change?

To provide WalletConnect support in the React Native SDK for better wallet management and interoperability.



PR-Codex overview

This PR adds wallet connect functionality to a React Native app.

Detailed summary

  • Added wallet connect functions to wallets.native.ts
  • Exported wallet connect client and session functions
  • Exported wallet connect types

✨ Ask PR-Codex anything about this PR by commenting with /codex {your question}

Copy link

vercel bot commented Jun 21, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
thirdweb_playground ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 21, 2024 8:12pm
thirdweb-www ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 21, 2024 8:12pm

Copy link

changeset-bot bot commented Jun 21, 2024

🦋 Changeset detected

Latest commit: fe77516

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 8 packages
Name Type
thirdweb Patch
@thirdweb-dev/sdk Patch
@thirdweb-dev/cli Patch
@thirdweb-dev/react-core Patch
@thirdweb-dev/react Patch
@thirdweb-dev/unity-js-bridge Patch
@thirdweb-dev/wallets Patch
@thirdweb-dev/auth Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
Contributor

graphite-app bot commented Jun 21, 2024

Your org requires the Graphite merge queue for merging into main

Add the label “merge-queue” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge. Or use the label “hotfix” to add to the merge queue as a hot fix.

You must have a Graphite account and log in to Graphite in order to use the merge queue. Sign up using this link.

@github-actions github-actions bot added the TS SDK Involves changes to the v5 TypeScript SDK. label Jun 21, 2024
Copy link
Member Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

Join @gregfromstl and the rest of your teammates on Graphite Graphite

Copy link

codspeed-hq bot commented Jun 21, 2024

CodSpeed Performance Report

Merging #3444 will not alter performance

Comparing chore/native-exports-wc (fe77516) with main (5f880b2)

Summary

✅ 9 untouched benchmarks

Copy link
Contributor

github-actions bot commented Jun 21, 2024

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
thirdweb (esm) 40.63 KB (0%) 813 ms (0%) 660 ms (+15.85% 🔺) 1.5 s
thirdweb (cjs) 91.84 KB (0%) 1.9 s (0%) 1.2 s (-6.17% 🔽) 3 s
thirdweb (minimal + tree-shaking) 4.79 KB (0%) 96 ms (0%) 46 ms (-46.49% 🔽) 142 ms
thirdweb/chains (tree-shaking) 423 B (0%) 10 ms (0%) 13 ms (+59.35% 🔺) 23 ms
thirdweb/react (minimal + tree-shaking) 13.49 KB (0%) 270 ms (0%) 134 ms (+55.39% 🔺) 404 ms

@gregfromstl gregfromstl force-pushed the chore/native-exports-wc branch from c12b28c to 9960e9a Compare June 21, 2024 18:38
@gregfromstl gregfromstl requested a review from jnsdls June 21, 2024 18:38
@gregfromstl gregfromstl changed the title chore: add missing walletconnect exports to RN wallet exports [Chore] Add missing walletconnect exports to RN wallet exports Jun 21, 2024
@gregfromstl gregfromstl marked this pull request as ready for review June 21, 2024 18:39
@@ -95,6 +95,19 @@ export { type WalletInfo } from "../wallets/wallet-info.js";

export { createWalletAdapter } from "../adapters/wallet-adapter.js";

// wallet connect
export {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

does this... work in react native?

Copy link
Member

@jnsdls jnsdls left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

generally makes sense, just unsure if walletconnectreceiver works in react native?

Copy link

codecov bot commented Jun 21, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 61.14%. Comparing base (5f880b2) to head (fe77516).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3444   +/-   ##
=======================================
  Coverage   61.14%   61.14%           
=======================================
  Files         891      891           
  Lines       67375    67375           
  Branches     3498     3498           
=======================================
  Hits        41196    41196           
  Misses      25496    25496           
  Partials      683      683           
Flag Coverage Δ *Carryforward flag
legacy_packages 65.60% <ø> (ø) Carriedforward from 5f880b2
packages 60.28% <ø> (ø)

*This pull request uses carry forward flags. Click here to find out more.

### TL;DR

Adds wallet connect functions to react native.

### What changed?

- Added `createWalletConnectClient`, `createWalletConnectSession`, `disconnectWalletConnectSession`, `getActiveWalletConnectSessions`, and `DefaultWalletConnectRequestHandlers` exports to `wallets.native.ts`
- Added type exports `WalletConnectClient` and `WalletConnectSession` to `wallets.native.ts`

### How to test?

1. Import the new functions and types in a React Native project.
2. Test creating, managing, and disconnecting WalletConnect sessions.

### Why make this change?

To provide WalletConnect support in the React Native SDK for better wallet management and interoperability.

---
Copy link
Contributor

graphite-app bot commented Jun 21, 2024

Merge activity

@graphite-app graphite-app bot merged commit fe77516 into main Jun 21, 2024
31 checks passed
@graphite-app graphite-app bot deleted the chore/native-exports-wc branch June 21, 2024 20:12
@jnsdls jnsdls mentioned this pull request Jun 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
TS SDK Involves changes to the v5 TypeScript SDK.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants