Skip to content
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

feat: sessionStorage for burner wallet #24

Merged
merged 7 commits into from
Dec 20, 2024

Conversation

rin-st
Copy link
Member

@rin-st rin-st commented Dec 17, 2024

Context: scaffold-eth/se-2-challenges#250 (comment)

Also, to make it work we need to add the possibility to export it to services/web3/wagmiConnectors.tsx. So we need to templatize that file

Do you have any thoughts on how to make it another way?

@technophile-04

Copy link
Collaborator

@technophile-04 technophile-04 left a comment

Choose a reason for hiding this comment

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

Thanks @rin-st! Just pushed b9b4f6b

I think people should be able to use either one of them not both at same time (rainbowkitBurnerConnector | rainbowkitSessionStorageBurnerWallet). But since we are exposing both people can use both at same time and that can cause issue.

So just updated it to hvae similar API to how rianbowkit coinbase wallet has:

Screenshot 2024-12-18 at 6 52 30 PM

So similar to this in our case people would consume sessionStorage in this way:

import { rainbowkitBurnerWallet } from "burner-connector";

rainbowkitBurnerWallet.useSessionStorage = true 

const wallets = [metaMaskWallet, rainbowkitBurnerWallet];

Copy link
Collaborator

@technophile-04 technophile-04 left a comment

Choose a reason for hiding this comment

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

Could u just give it a last pair of eyes / thoughts on last commit 🙌. Happy to merge without last commit but I think it makes more sense to have the API like this but not too strong opinion.

@rin-st
Copy link
Member Author

rin-st commented Dec 18, 2024

Yes I agree, thank you!

Added small fix for default value and network

@rin-st rin-st marked this pull request as ready for review December 19, 2024 11:51
@technophile-04 technophile-04 changed the title Rainbowkit sessionStorage burner wallet feat: sessionStorage for burner wallet Dec 20, 2024
@technophile-04
Copy link
Collaborator

Thanks @rin-st! Merging this 🙌

@technophile-04 technophile-04 merged commit 1849aec into scaffold-eth:main Dec 20, 2024
1 check passed
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.

2 participants