Migration Guide

From RainbowKit to TomoEVMKit

1

Update Imports

// Old
import '@rainbow-me/rainbowkit/styles.css';
import { RainbowKitProvider } from '@rainbow-me/rainbowkit';

import { metaMaskWallet, walletConnectWallet, coinbaseWallet } from '@rainbow-me/rainbowkit/wallets';


// New
import '@tomo-inc/tomo-evm-kit/styles.css';
import { TomoEVMKitProvider } from '@tomo-inc/tomo-evm-kit';

import { metaMaskWallet, walletConnectWallet, coinbaseWallet } from '@tomo-inc/tomo-evm-kit/wallets';
2

Add `clientId` to config

const config = getDefaultConfig({
  appName: 'My TomoEVMKit App',

  // New
  clientId: 'XXXXXXXXXXXXXXXXXXXXXXX', // Replace with your clientId
});
3

Replace RainbowKitProvider with TomoEVMKitProvider

// Old
<RainbowKitProvider>
  {/* Your App */}
</RainbowKitProvider>

// New
<TomoEVMKitProvider>
  {/* Your App */}
</TomoEVMKitProvider>

Security Enhancements

• App information is now securely fetched from an API using the `clientId`.

• This prevents phishing risks from malicious websites.

Last updated