Update components/providers/privy-provider.tsx
This commit is contained in:
parent
6d0733fc67
commit
e1f0c44569
@ -2,7 +2,6 @@
|
|||||||
|
|
||||||
import { PrivyProvider } from '@privy-io/react-auth';
|
import { PrivyProvider } from '@privy-io/react-auth';
|
||||||
import { ReactNode , useEffect } from 'react';
|
import { ReactNode , useEffect } from 'react';
|
||||||
// import {toSolanaWalletConnectors} from '@privy-io/react-auth/solana';
|
|
||||||
|
|
||||||
export function Providers({ children }: { children: ReactNode }) {
|
export function Providers({ children }: { children: ReactNode }) {
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
@ -10,12 +9,6 @@ export function Providers({ children }: { children: ReactNode }) {
|
|||||||
localStorage.removeItem('privy:embedded-wallet:ready');
|
localStorage.removeItem('privy:embedded-wallet:ready');
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
// const solanaConnectors = toSolanaWalletConnectors({
|
|
||||||
// // By default, shouldAutoConnect is enabled
|
|
||||||
// shouldAutoConnect: true,
|
|
||||||
// });
|
|
||||||
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<PrivyProvider
|
<PrivyProvider
|
||||||
appId={process.env.NEXT_PUBLIC_PRIVY_APP_ID || ''}
|
appId={process.env.NEXT_PUBLIC_PRIVY_APP_ID || ''}
|
||||||
@ -28,11 +21,6 @@ export function Providers({ children }: { children: ReactNode }) {
|
|||||||
"walletChainType": 'ethereum-only',
|
"walletChainType": 'ethereum-only',
|
||||||
"walletList": ['metamask', 'wallet_connect', 'coinbase_wallet', 'rabby_wallet', 'cryptocom','safe']
|
"walletList": ['metamask', 'wallet_connect', 'coinbase_wallet', 'rabby_wallet', 'cryptocom','safe']
|
||||||
},
|
},
|
||||||
// "externalWallets": {
|
|
||||||
// "solana": {
|
|
||||||
// "connectors": solanaConnectors,
|
|
||||||
// },
|
|
||||||
// },
|
|
||||||
"loginMethods": [
|
"loginMethods": [
|
||||||
"email",
|
"email",
|
||||||
"wallet"
|
"wallet"
|
||||||
@ -44,7 +32,14 @@ export function Providers({ children }: { children: ReactNode }) {
|
|||||||
},
|
},
|
||||||
"mfa": {
|
"mfa": {
|
||||||
"noPromptOnMfaRequired": false
|
"noPromptOnMfaRequired": false
|
||||||
}
|
},
|
||||||
|
"defaultChain": 56, // BSC mainnet
|
||||||
|
"supportedChains": [{
|
||||||
|
id: 56,
|
||||||
|
name: 'BNB Smart Chain',
|
||||||
|
rpcUrl: 'https://bsc-dataseed.binance.org/',
|
||||||
|
blockExplorer: 'https://bscscan.com'
|
||||||
|
}]
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{children}
|
{children}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user