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

@ensdomains/etherloom

v0.1.0-alpha.4

Published

Deterministic SVG weave patterns generated from an Ethereum address.

Readme

etherloom

Deterministic SVG weave patterns for ENS names - a generative, on-chain-ready avatar for every name. The same name always looms the same identicon, and different names render different cloth, so nick.eth and vibes.eth are instantly distinguishable. Bind a name to its owner and the weave is re-woven when the name changes hands.

  • ENS-native. Seed from a name's namehash so every name gets its own weave; combine it with the owner address so the pattern changes on transfer, or use the name alone for an identity that stays put across transfers.
  • Plain Ethereum addresses work too. No ENS name? Pass a bare address for the classic wallet identicon - same library, no extra setup, output unchanged.
  • The identity picks the weave; the color is a parameter you pass and never changes the structure (recolor any identity freely).
  • 18 named weaves, two render styles: tiles (default, icon look - two-tone vertical pills on a soft frame) and threads (dense fabric).
  • Effectively unique per identity: it deterministically picks one of 18 weaves (via patternForIdentity / generateIdenticon) and seeds each variant, so distinct identities don't collide. See Identity.

Usage

import {
  generateIdenticon,
  patternForIdentity,
  generatePattern,
  generatePatternDataURI,
  generateAllPatterns,
  listPatterns,
} from "./etherloom";
import { namehash } from "viem/ens";

// ENS-native: one woven avatar per name (color is required, #RGB or #RRGGBB).
generateIdenticon({ namehash: namehash("vitalik.eth") }, "#f03090");

// Bind the name to its owner so the weave changes hands with the name.
generateIdenticon({ address: "0xd8dA…6045", namehash: namehash("vitalik.eth") }, "#f03090");

// No ENS name? A bare address still works - the classic wallet identicon.
generateIdenticon("0xd8dA…6045", "#f03090");

// Which weave a name maps to, and picking the weave yourself:
patternForIdentity({ namehash: namehash("nick.eth") });                        // -> "Herringbone", etc.
generatePattern({ namehash: namehash("nick.eth") }, "Herringbone", "#f03090"); // explicit weave override

// options: backgroundColor, style ("tiles" | "threads"), width, height, cellSize
generatePattern({ namehash: namehash("nick.eth") }, "2-2 Twill", "#3366cc", { width: 240, height: 240, cellSize: 24 });
generatePattern("0xd8dA…6045", "Herringbone", "#f03090", { style: "threads" });

generateAllPatterns({ namehash: namehash("nick.eth") }, "#2e9e5b");                    // all 18 as SVG
generatePatternDataURI({ namehash: namehash("nick.eth") }, "Basket Weave", "#ff9800"); // data: URI for <img>

Identity: an ENS name, an address, or both

Every entry point takes an identity. The ENS-native path is a name's namehash - a precomputed bytes32 node from viem's namehash() or @ensdomains/ensjs. This library stays dependency-free and never normalizes names itself, so you pass the node, not the name string:

import { namehash } from "viem/ens";

// Name only: one avatar per name, stable across ownership transfers.
generateIdenticon({ namehash: namehash("vitalik.eth") }, "#f03090");

// Name + owner: the weave is re-woven if the name changes hands.
generateIdenticon({ address: "0xd8dA…6045", namehash: namehash("vitalik.eth") }, "#f03090");

// Power user / no ENS: a bare address string, or a zero / omitted namehash -
// the classic wallet identicon, byte-for-byte unchanged.
generateIdenticon("0xd8dA…6045", "#f03090");
generateIdenticon({ address: "0xd8dA…6045", namehash: "0x0" }, "#f03090"); // same as above

| namehash | address | result | | -------------- | --------- | ------------------------------------------------------ | | set | omitted | name avatar, stable across transfers (ENS-native) | | set | set | name avatar that changes with the owner | | zero / omitted | set | address identicon (power user / no ENS) |

The 0x prefix and case of the namehash don't matter, and the all-zero ENS root node (0x0) is the "no name" sentinel that falls back to address-only seeding.

Scripts

pnpm install
pnpm test        # node:test suite
pnpm demo        # console demo
pnpm gallery     # write gallery.html and open it  (optional:  pnpm gallery 0xAddr "#color")

Interactive demo

docs/ has two static pages - enter an ENS name or Ethereum address (resolved with viem) and a color:

  • identicon.html - one identity-driven weave (generateIdenticon)
  • index.html - all 18 patterns for comparison
pnpm build:web
pnpm dlx serve docs
# identicon -> http://localhost:3000/identicon.html
# all patterns -> http://localhost:3000/

Patterns

Matt Rib Irregular · ENS Vertical Pairs · Plain Weave · Warp Rib Regular · Weft Rib Regular · Satin Weave · Houndstooth · Sateen Weave · Royal Oxford · 2-2 Twill · 3-3 Twill · Weft Rib Irregular · Warp Rib Irregular · Basket Weave · Point Twill · Curtain · Herringbone · 738 Diagonal Plus

License

MIT © ENS Labs