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

winnode

v1.0.1

Published

WinScan Tx SDK - Transaction toolkits for Cosmos SDK and EVM chains

Readme

WinNode SDK

npm version CI License: MIT

Transaction toolkits for Cosmos SDK and EVM chains — send, delegate, vote, and more, with a small dependency-free isEvmChain helper to pick the right toolkit for a given chain.

Features

  • Cosmos SDK (cosmosTx) — send, delegate, undelegate, redelegate, vote, unjail, withdrawRewards. Signs via any OfflineSigner-compatible wallet (Keplr, Leap, etc).
  • EVM chains (evmTx) — sendNative, sendToken, writeContract. Signs via the injected browser wallet (MetaMask).
  • Chain-type detectionisEvmChain(chain) picks which toolkit applies based on coin_type / evm_rpc.
  • Ships as CJS, ESM, and TypeScript types.

Installation

npm install winnode

Requires Node.js 18+ and (for EVM signing) a browser environment with MetaMask injected as window.ethereum.

Usage

import { isEvmChain, cosmosTx, evmTx } from 'winnode';
import type { ChainData } from 'winnode';

declare const chain: ChainData;

if (isEvmChain(chain)) {
  // EVM chain
  const signer = await evmTx.getBrowserSigner(chain);
  const result = await evmTx.sendNative(signer, {
    toAddress: '0x...',
    amount: '1.5',
  });
} else {
  // Cosmos SDK chain
  const result = await cosmosTx.send(chain, offlineSigner, {
    fromAddress: 'cosmos1...',
    toAddress: 'cosmos1...',
    amount: '1000000',
  });
}

ChainData

Both toolkits take a ChainData describing the chain (see types/chain.ts): chain_name, chain_id, coin_type, assets, rpc, evm_rpc, evm_chain_id, and fees.fee_tokens (used for Cosmos fee calculation).

Cosmos SDK API (cosmosTx)

| Function | Description | | --- | --- | | send(chain, signer, params, opts?) | MsgSend | | delegate(chain, signer, params, opts?) | MsgDelegate | | undelegate(chain, signer, params, opts?) | MsgUndelegate | | redelegate(chain, signer, params, opts?) | MsgBeginRedelegate | | vote(chain, signer, params, opts?) | MsgVote | | unjail(chain, signer, params, opts?) | MsgUnjail | | withdrawRewards(chain, signer, params, opts?) | MsgWithdrawDelegatorReward | | getSigningStargateClient(chain, signer) | Cached SigningStargateClient |

Every function returns a Promise<TxResult>: { success: boolean; txHash?: string; error?: string; raw?: any }.

EVM API (evmTx)

| Function | Description | | --- | --- | | sendNative(signer, params, opts?) | Send the chain's native coin | | sendToken(signer, params, opts?) | ERC-20 transfer | | writeContract(signer, address, abi, method, args?, opts?) | Generic contract write (e.g. staking/gov precompiles) | | getReadProvider(chain) | Read-only JsonRpcProvider | | getBrowserSigner(chain) | MetaMask-backed JsonRpcSigner, switching chains as needed |

Development

npm install         # install dependencies
npm run build        # build dist/ (CJS + ESM + types via tsup)
npm run typecheck    # tsc --noEmit
npm run lint         # eslint .
npm test             # vitest run

Releasing

Versions are bumped with npm version, which updates package.json, commits the change, and creates a matching git tag:

npm version patch   # bug fixes: 1.0.0 -> 1.0.1
npm version minor   # new features: 1.0.0 -> 1.1.0
npm version major   # breaking changes: 1.0.0 -> 2.0.0

Before bumping, add an entry to CHANGELOG.md describing what changed. Push the resulting commit and tag to main (git push && git push --tags); the Publish to npm workflow lints, typechecks, tests, builds, and publishes the package automatically.

Security

See SECURITY.md for supported versions and how to report a vulnerability.

License

MIT