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

Redirect to the original action after connecting wallet #72

Open
thisisommore opened this issue Aug 30, 2022 · 0 comments
Open

Redirect to the original action after connecting wallet #72

thisisommore opened this issue Aug 30, 2022 · 0 comments

Comments

@thisisommore
Copy link
Member

It will be good UX if it redirects you to required action next, like when you click mint it will give you MetaMask pop up, you connect, and then it will automatically open mint modal you don't need to press mint button again.

It can done in two ways

  1. Callback
  2. Promise(Preferred)
    And can be done via introducing new function in context like withContext which calls the callback (resolves in case of promise) with the web3 provider in it

Also there is issue with context, it rerenders everything who is consumer of it, so we can lost the action callback. But we can tackle this by removing all states and using React Ref when possible, but again we cannot always use React Ref, like Wallet Address state
Originally posted by @thisisommore in #63 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 🆕 New
Development

No branches or pull requests

1 participant