-
Notifications
You must be signed in to change notification settings - Fork 7
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
Deeplinks #134
Deeplinks #134
Conversation
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
3138bdf
to
037d4b0
Compare
cb03968
to
a6ca608
Compare
This PR adds a support for deeplinks and adds deeplinks to wallets adapters for wallets, supporting deeplinks.
Resolves SI-955, SI-963, SI-986
How it works in general:
A user takes a mobile device, opens a regular mobile browser like Safari, opens dApp in it and clicks on a wallet connection button.
window.ethereum
is found), then it will be connected and that's it.Detection of a wallet app on a user's device
We are not able to detect if some mobile app, which wasn't developed by us, is installed on a user's device. This is right, at least for security reasons.
Some wallets provide a web page like https://metamask.app.link, which can detect if a wallet app is installed and redirect a user to a deeplink in this case. And redirect to the download page otherwise. If a wallet provides such a page, we use it.
But not all wallets do this. For example, imToken just provides a raw deeplink without ability to detect if a wallet is installed. So, if a user opens a dApp on a mobile device in a mobile browser, clicks imToken to connect, but it is not installed on the device, then the user will get an empty white page in the browser. And it seems, there is nothing can be done with it.
Wallets affected
Deeplinks were added for: MetaMask, BitKeep, Coin98, imToken, OKX, Trust wallets.