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

@thenamespace/ens-components

v1.1.1

Published

Production-ready React components for ENS name registration, record editing, and subname issuance.

Readme

@thenamespace/ens-components

Production-ready React components for ENS name registration, record editing, and subname issuance.

npm

Install

npm install @thenamespace/ens-components
# or
pnpm add @thenamespace/ens-components

Peer dependencies (you likely already have these):

npm install react react-dom wagmi viem

Quick start

1. Wrap your app with Web3 providers

The library reads wallet state from wagmi. Use your own wagmi setup or RainbowKit:

import { getDefaultConfig, RainbowKitProvider } from "@rainbow-me/rainbowkit";
import { WagmiProvider } from "wagmi";
import { mainnet, sepolia } from "wagmi/chains";
import { QueryClientProvider, QueryClient } from "@tanstack/react-query";
import "@rainbow-me/rainbowkit/styles.css";

const config = getDefaultConfig({
  appName: "My App",
  projectId: "YOUR_WALLETCONNECT_PROJECT_ID",
  chains: [mainnet, sepolia],
});

export function Providers({ children }: { children: React.ReactNode }) {
  return (
    <WagmiProvider config={config}>
      <QueryClientProvider client={new QueryClient()}>
        <RainbowKitProvider>{children}</RainbowKitProvider>
      </QueryClientProvider>
    </WagmiProvider>
  );
}

2. Import styles

import "@thenamespace/ens-components/styles";

3. Drop in a component

import { EnsNameRegistrationForm } from "@thenamespace/ens-components";

export default function App() {
  return <EnsNameRegistrationForm isTestnet={false} />;
}

Components

EnsNameRegistrationForm

Full .eth name registration flow: search → commit → wait → register.

<EnsNameRegistrationForm
  isTestnet={false}
  onNameRegistered={(name) => console.log("Registered:", name)}
/>

| Prop | Type | Description | |------|------|-------------| | isTestnet | boolean | Use Sepolia testnet contracts | | onNameRegistered | (name: string) => void | Callback after successful registration |


EnsRecordsForm

Edit all resolver records for an ENS name — addresses, text records, contenthash, avatar, and header image.

<EnsRecordsForm
  name="alice.eth"
  existingRecords={{ texts: [], addresses: [] }}
  isTestnet={false}
  onRecordsSaved={(records) => console.log(records)}
/>

| Prop | Type | Description | |------|------|-------------| | name | string | The ENS name to edit | | existingRecords | EnsRecords | Current on-chain records to pre-populate | | isTestnet | boolean | Use Sepolia testnet contracts | | onRecordsSaved | (records: EnsRecords) => void | Callback after records are saved |


SubnameMintForm

Mint an onchain subname from a Namespace listing.

<SubnameMintForm
  parentName="alice.eth"
  isTestnet={false}
  onSubnameMinted={(subname) => console.log("Minted:", subname)}
/>

| Prop | Type | Description | |------|------|-------------| | parentName | string | Parent ENS name with an active listing | | isTestnet | boolean | Use Sepolia testnet contracts | | onSubnameMinted | (subname: string) => void | Callback after mint |


OffchainSubnameForm

Create or update an offchain subname through the Namespace API.

<OffchainSubnameForm
  name="alice.eth"
  apiKeyOrToken="YOUR_NAMESPACE_API_KEY"
  isTestnet={false}
  onSubnameSaved={(subname) => console.log("Saved:", subname)}
/>

| Prop | Type | Description | |------|------|-------------| | name | string | Parent ENS name | | apiKeyOrToken | string | Namespace API key or SIWE token | | isTestnet | boolean | Use Sepolia testnet contracts | | onSubnameSaved | (subname: string) => void | Callback after save |


Hooks

import {
  useRegisterENS,
  useENSResolver,
  useMintSubname,
  useOffchainManager,
  useWaitTransaction,
  useAvatarClient,
} from "@thenamespace/ens-components";

Types

import type {
  EnsRecords,
  EnsTextRecord,
  EnsAddressRecord,
  EnsContenthashRecord,
} from "@thenamespace/ens-components";

Theming

Components use CSS variables that can be overridden:

:root {
  --ns-color-primary: #5A4BFF;
  --ns-color-bg: #ffffff;
  --ns-color-fg: #111111;
  --ns-radius-md: 12px;
  --ns-font-family: "DM Sans", sans-serif;
}

Links