-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: forgot to comment out web3modal
- Loading branch information
Showing
1 changed file
with
15 additions
and
15 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
import { useState, useEffect } from 'react'; | ||
import { EthereumProvider } from '@walletconnect/ethereum-provider'; | ||
import { IEthereumProvider } from '@walletconnect/ethereum-provider/dist/types/EthereumProvider'; | ||
const projectId = '2d923a8a66e396445ba00cd8b882450b'; | ||
// import { useState, useEffect } from 'react'; | ||
// import { EthereumProvider } from '@walletconnect/ethereum-provider'; | ||
// import { IEthereumProvider } from '@walletconnect/ethereum-provider/dist/types/EthereumProvider'; | ||
// const projectId = '2d923a8a66e396445ba00cd8b882450b'; | ||
|
||
export const useWeb3Modal = () => { | ||
const [provider, setProvider] = useState<IEthereumProvider>(); | ||
// export const useWeb3Modal = () => { | ||
// const [provider, setProvider] = useState<IEthereumProvider>(); | ||
|
||
useEffect(() => { | ||
EthereumProvider.init({ | ||
projectId, // REQUIRED your projectId | ||
chains: [122, 42220], // REQUIRED chain ids | ||
showQrModal: true, // REQUIRED set to "true" to use @walletconnect/modal | ||
}).then((_) => setProvider(_)); | ||
}, []); | ||
// useEffect(() => { | ||
// EthereumProvider.init({ | ||
// projectId, // REQUIRED your projectId | ||
// chains: [122, 42220], // REQUIRED chain ids | ||
// showQrModal: true, // REQUIRED set to "true" to use @walletconnect/modal | ||
// }).then((_) => setProvider(_)); | ||
// }, []); | ||
|
||
return provider; | ||
}; | ||
// return provider; | ||
// }; |