Implemented Connect with Metamask for signup#159
Open
dev-Aarish wants to merge 3 commits into
Open
Conversation
|
@dev-Aarish is attempting to deploy a commit to the daviddprtma's projects Team on Vercel. A member of the Team first needs to authorize it. |
daviddprtma
reviewed
Jun 23, 2026
| * Check if MetaMask or any EIP-1193 provider is installed | ||
| */ | ||
| export function isMetaMaskInstalled(): boolean { | ||
| return typeof window !== "undefined" && typeof (window as Record<string, any>).ethereum !== "undefined"; |
Owner
There was a problem hiding this comment.
can you comment in the above with this // eslint-disable-next-line @typescript-eslint/no-explicit-any ?? because in the frontend CI, it's failed to passed it.
Added ESLint directive to ignore explicit any type check. Signed-off-by: Aritro Bag <aritrobag362@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pull Request — AgroDex
📌 Related Issue
Fixes #76
Description of Changes
Added MetaMask sign-in via Supabase Web3 Auth (EIP-4361).
When the user clicks Connect MetaMask, the app detects the MetaMask extension, requests account access, ensures the wallet is on Hedera Testnet (auto-switching or adding the network if needed), and then calls Supabase's built-in signInWithWeb3 to generate and sign an Ethereum authentication challenge, creating a session without needing an email or password.
Type of Change
📸 Screenshots / Video
✅ Checklist
💬 Additional Notes (Optional)
Currently the signing process by supabase is done on the production url
https://agro-dex-1u85.vercel.app/and might fail when thesupabase.auth.signInWithWeb3has the localhost url. It would work on the localhost url when that is added to one of the site url in the supabase project.