🖥
For Developers
To detect if users are accessing your dApp on Fina, you can check if the following object exist.
window.fina
If this is
undefined
that means user is not accessing your dApp via Fina Wallet's in-app browser.Besides, the
window.fina
object is just a pointer to window.keplr
so the underlying methods and properties will be the sameIf you want to redirect users from your dApp to Fina Wallet, you can use the following deep link
fina://wallet
If you want to redirect users to your dApp directly on Fina's in-app browser, you can use the following deep link
fina://wallet/dapps?network=secret-4&url=https%3A%2F%2Fcard.fina.cash
There are 2 url parameters in the deep link
- 1.
network
- the chain ID of the network your dApp is connecting to - 2.
url
- your dApp's URL-encoded url
const urlSearchParams = new URLSearchParams();
urlSearchParams.append("network", "secret-4");
urlSearchParams.append("url", window.location.href);
window.open(`fina://wllet/dapps?${urlSearchParams.toString()}`, "_blank");
Last modified 2mo ago