Skip to content

Instantly share code, notes, and snippets.

@KarthickNcog
Created October 3, 2023 11:10
Show Gist options
  • Select an option

  • Save KarthickNcog/6edb349b31cd0fd25d9e9939a0d648e9 to your computer and use it in GitHub Desktop.

Select an option

Save KarthickNcog/6edb349b31cd0fd25d9e9939a0d648e9 to your computer and use it in GitHub Desktop.
Rainbow kit Network Connection
const ncogEarthChainTestNet: Network = {
id: 2528,
name: 'NEC Testnet',
network: 'ncogEarthChainTestnet',
iconUrl: 'https://example.com/icon.svg',
iconBackground: '#fff',
nativeCurrency: {
decimals: 18,
name: 'NEC Token',
symbol: 'NEC',
},
rpcUrls: {
default: {
http: ['https://api-test.ncogchain.earth'],
webSocket: ['wss://api-test.ncogchain.earth'],
},
public : {
http: ['https://api-test.ncogchain.earth'],
}
},
blockExplorers: {
default: { name: 'NEC Explorer', url: 'https://explorer-test.ncogchain.earth/' }
},
testnet: true,
};
const ncogEarthChainLiveNet: Network = {
id: 2540,
name: 'NCOG Earth Chain',
network: 'ncogEarthChainLiveNet',
iconUrl: 'https://example.com/icon.svg',
iconBackground: '#fff',
nativeCurrency: {
decimals: 18,
name: 'NEC Token',
symbol: 'NEC',
},
rpcUrls: {
default: {
http: ['https://api.ncogchain.earth'],
webSocket: ['wss://api.ncogchain.earth'],
},
public : {
http: ['https://api.ncogchain.earth'],
}
},
blockExplorers: {
default: { name: 'NEC Explorer', url: 'https://explorer.ncogchain.earth/' }
},
testnet: true,
};
const { chains, publicClient, webSocketPublicClient } = configureChains(
[
ncogEarthChainTestNet,
ncogEarthChainLiveNet,
],
[publicProvider()]
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment