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

@shelchin/walletkit

v0.0.2

Published

<div align="center"> <h3>Modern Ethereum Wallet Connection Library for Svelte</h3> <p>Lightweight, customizable, and feature-rich wallet connection solution</p>

Readme

WalletKit

English | 简体中文

✨ Features

  • 🚀 Lightweight - Built with Viem instead of Wagmi, core library < 50KB gzipped
  • 🌍 Multi-Chain Support - Seamless network switching with RPC load balancing
  • 🔐 Extensive Wallet Support - MetaMask, WalletConnect, Coinbase, Safe, Ledger, and EIP-6963 auto-detection
  • 🎨 Fully Customizable - Complete theming system with dark mode support
  • 🌐 i18n Ready - Built-in internationalization support
  • 📱 Mobile Optimized - Responsive design with touch-friendly interactions
  • 🔧 Framework Agnostic - Use as NPM package or standalone script
  • 🛡️ Type Safe - Full TypeScript support with comprehensive type definitions

📦 Installation

NPM Package (for Svelte apps)

npm install @shelchin/walletkit
# or
pnpm add @shelchin/walletkit
# or
yarn add @shelchin/walletkit

Standalone Script (for any website)

<script src="https://unpkg.com/@shelchin/walletkit/dist/standalone.js"></script>

🚀 Quick Start

Svelte Component

<script>
	import { WalletKit, WalletButton } from '@shelchin/walletkit';

	const config = {
		projectId: 'YOUR_WALLETCONNECT_PROJECT_ID', // Required for WalletConnect
		networks: [1, 137, 42161], // Ethereum, Polygon, Arbitrum
		theme: 'auto', // 'light' | 'dark' | 'auto'
		locale: 'en' // 'en' | 'zh'
	};
</script>

<WalletKit {config}>
	<WalletButton />
</WalletKit>

Standalone Usage

<div id="wallet-container"></div>

<script src="https://unpkg.com/@shelchin/walletkit/dist/standalone.js"></script>
<script>
	WalletKit.init({
		containerId: 'wallet-container',
		projectId: 'YOUR_WALLETCONNECT_PROJECT_ID',
		theme: 'dark',
		networks: [1, 137, 42161]
	});
</script>

🛠️ Advanced Configuration

Complete Configuration Options

interface WalletKitConfig {
	// WalletConnect Project ID (required for WalletConnect)
	projectId?: string;

	// Supported networks (chain IDs)
	networks?: number[];

	// Custom RPC endpoints
	rpcUrls?: Record<number, string[]>;

	// Theme configuration
	theme?: 'light' | 'dark' | 'auto' | ThemeConfig;

	// Localization
	locale?: 'en' | 'zh' | LocaleConfig;

	// Wallet options
	wallets?: {
		includeDefault?: boolean;
		custom?: WalletConfig[];
	};

	// Features
	features?: {
		ensResolution?: boolean;
		siwe?: boolean; // Sign-In with Ethereum
		analytics?: boolean;
	};

	// Custom modal options
	modal?: {
		disableBackdropClick?: boolean;
		showRecentTransactions?: boolean;
	};
}

Custom Theme

const customTheme = {
	colors: {
		primary: '#6366f1',
		background: '#ffffff',
		text: '#111827',
		border: '#e5e7eb'
	},
	radius: {
		button: '0.75rem',
		modal: '1.5rem'
	},
	fonts: {
		base: 'Inter, system-ui, sans-serif'
	}
};

WalletKit.init({
	theme: customTheme
});

Custom Networks

const customNetworks = {
	networks: [1, 137, 42161, 56], // Include BSC
	rpcUrls: {
		1: ['https://eth-mainnet.g.alchemy.com/v2/YOUR_KEY'],
		137: ['https://polygon-rpc.com'],
		42161: ['https://arb1.arbitrum.io/rpc'],
		56: ['https://bsc-dataseed.binance.org']
	}
};

📱 Mobile Support

WalletKit is fully optimized for mobile devices with:

  • Touch-friendly interface
  • Bottom sheet modals on mobile
  • QR code scanning for WalletConnect
  • Deep linking support
  • Responsive design

🎨 Theming

Built-in Themes

  • Light - Clean and modern light theme
  • Dark - Eye-friendly dark theme
  • Auto - Follows system preferences

Custom Theming

import { createTheme } from '@shelchin/walletkit';

const myTheme = createTheme({
	primary: '#8b5cf6',
	secondary: '#ec4899',
	borderRadius: 'lg',
	fontFamily: 'Roboto, sans-serif'
});

🌍 Internationalization

Supported Languages

  • English (en)
  • 简体中文 (zh)

Custom Translations

const customLocale = {
	connect: 'Connect Wallet',
	disconnect: 'Disconnect',
	switchNetwork: 'Switch Network',
	copyAddress: 'Copy Address'
	// ... more translations
};

WalletKit.init({
	locale: customLocale
});

🔌 API Reference

Core Methods

// Initialize WalletKit
WalletKit.init(config: WalletKitConfig): void

// Connect wallet
WalletKit.connect(): Promise<WalletConnection>

// Disconnect wallet
WalletKit.disconnect(): Promise<void>

// Get current account
WalletKit.getAccount(): Address | null

// Switch network
WalletKit.switchNetwork(chainId: number): Promise<void>

// Sign message
WalletKit.signMessage(message: string): Promise<string>

// Send transaction
WalletKit.sendTransaction(tx: TransactionRequest): Promise<string>

Event Listeners

// Account change
WalletKit.onAccountChange((account) => {
	console.log('Account changed:', account);
});

// Network change
WalletKit.onChainChange((chainId) => {
	console.log('Network changed:', chainId);
});

// Connection status
WalletKit.onConnectionChange((connected) => {
	console.log('Connection status:', connected);
});

Svelte Stores

import { account, chainId, connected, connecting } from '@shelchin/walletkit';

// Use in Svelte components
$: currentAccount = $account;
$: currentChain = $chainId;
$: isConnected = $connected;

🏗️ Architecture

WalletKit follows Clean Architecture principles:

src/
├── lib/
│   ├── domain/          # Business logic & types
│   ├── application/     # Use cases & services
│   ├── infrastructure/  # External integrations
│   └── presentation/    # UI components
├── standalone/          # Standalone build entry
└── routes/             # Demo pages

🧪 Development

Setup

# Install dependencies
pnpm install

# Start development server
pnpm dev

# Run tests
pnpm test

# Build library
pnpm build

# Lint & format
pnpm lint
pnpm format

Testing

# Unit tests
pnpm test:unit

# E2E tests
pnpm test:e2e

# Type checking
pnpm check

📄 License

MIT © 2025 WalletKit

🤝 Contributing

Contributions are welcome! Please read our Contributing Guide for details.

🔗 Links

💖 Sponsors

Special thanks to all our sponsors and contributors!