npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@tomo-inc/wlfi-wallet-connect-kit

v0.2.1

Published

A lightweight React SDK to integrate crypto wallet connection into your app. It ships with a configurable wallet list modal and basic account actions. The current focus is EVM, built on top of `@tomo-inc/wallet-adaptor-base`, and supports custom wallets a

Downloads

625

Readme

Wallet Connect SDK

A lightweight React SDK to integrate crypto wallet connection into your app. It ships with a configurable wallet list modal and basic account actions. The current focus is EVM, built on top of @tomo-inc/wallet-adaptor-base, and supports custom wallets and chain configuration.

Quick Start

// App.tsx — wrap your app with provider (comments in English)
import React from "react";
import { WalletConnectProvider } from "@tomo-inc/wlfi-wallet-connect-kit";

export default function App() {
  return (
    <WalletConnectProvider>
      <YourApp />
    </WalletConnectProvider>
  );
}

Open modal, connect and disconnect

import React from "react";
import { useWalletConnect } from "@tomo-inc/wlfi-wallet-connect-kit";

export function ConnectButton() {
  const { openModal, isConnected, disconnect } = useWalletConnect();

  return (
    <button onClick={() => (isConnected ? disconnect() : openModal())}>
      {isConnected ? "Disconnect" : "Connect Wallet"}
    </button>
  );
}

Read account and sign

import React from "react";
import { useAccount } from "@tomo-inc/wlfi-wallet-connect-kit";

export function AccountInfo() {
  const { address, chainId, signMessage, signInWithWallet } = useAccount();

  const onSignMessage = async () => {
    // Message signing for verification
    const sig = await signMessage?.({ message: "Hello Tomo" });
    console.log("signature:", sig);
  };

  const onSignin = async () => {
    // SIW (sign-in with wallet) to get a token
    const token = await signInWithWallet();
    console.log("token:", token);
  };

  return (
    <div>
      <div>Address: {address}</div>
      <div>ChainId: {chainId}</div>
      <button onClick={onSignMessage}>Sign Message</button>
      <button onClick={onSignin}>Sign In With Wallet</button>
    </div>
  );
}

Optional: custom wallets and chains

import React from "react";
import {
  WalletConnectProvider,
  type Chain,
} from "@tomo-inc/wlfi-wallet-connect-kit";

const config = {
  // Custom wallet connectors (merge with defaults)
  connectors: [
    {
      id: "my-wallet",
      name: "My Wallet",
      namespace: "my.wallet",
      icon: "https://example.com/icon.png",
      iconBackground: "#000",
      downloadUrls: { chrome: "https://example.com/install" },
    },
  ],
  // Supported chains by chain type (compatible with viem/Chain for EVM)
  chains: {
    evm: [
      {
        id: 1,
        name: "Ethereum",
        nativeCurrency: { name: "Ether", symbol: "ETH", decimals: 18 },
        rpcUrls: { default: { http: ["https://eth.merkle.io"] } },
        blockExplorers: {
          default: { name: "Etherscan", url: "https://etherscan.io" },
        },
      } as Chain,
    ],
    // aptos: [...],
    // solana: [...],
  },
  // Optional: WalletConnect protocol configuration
  // walletConnectConfig: { ... },

  // Optional: Embedded wallet configuration for social login
  embeddedWalletConfig: {
    apiKey: "your-api-key",
    // ... other embedded wallet settings
  },

  // Optional: Product type for UI theme (default: "tomo")
  prodType: "mydoge", // or "tomo"
};

export function AppWithConfig() {
  return (
    <WalletConnectProvider config={config}>
      <YourApp />
    </WalletConnectProvider>
  );
}

Exports

  • WalletConnectProvider - Main provider component with optional config prop
  • useWalletConnect - Hook for modal control and connection state: { isOpenModal, openModal, closeModal, isConnected, isConnecting, error, connect, disconnect }
  • useAccount - Hook for account info and actions: { address, balance, chainType, chainId, currentWallet, currentProvider, switchChain, signMessage, signInWithWallet }
  • Types: WalletConnectKitConfig, Chain, WalletProvider, UseAccount, UseWalletConnect, ChainType, ModalView
  • Views: MyDogeSocialLoginView - Custom MyDoge-styled social login view with Twitter, Google login and email support

WalletConnectProvider Config

The config prop accepts:

  • connectors?: WalletConfig[] - Custom wallet connectors to merge with defaults
  • chains?: Partial<Record<ChainType, EvmChain[] | any[]>> - Supported chains by chain type (e.g., { evm: [...], aptos: [...], solana: [...] })
  • walletConnectConfig?: WalletConnectProtocolConfig - WalletConnect protocol configuration
  • embeddedWalletConfig?: InitConfig - Embedded wallet configuration for social login features (API key, OAuth settings, etc.)
  • prodType?: ProdTypeEnum - Product type to determine UI theme ("tomo" or "mydoge"). Controls which social login view is displayed by default

Note: When prodType is set to "mydoge", the SDK will automatically use the MyDoge-styled UI theme for social login features. Set it to "tomo" or leave it unset for the default Tomo theme.

For more comprehensive examples, see EXAMPLE.md in the same directory.