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

@taghost/react

v3.1.0

Published

Invisible React SDK for TagHost Edge Visual CMS and Lead Routing

Readme

@taghost/react

The invisible React SDK for TagHost. It gives your app the two things the platform provides at the edge: a visual CMS your marketers can edit in place, and lead capture that works without a server.

There is no wrapper provider and no runtime to configure. Import what you need and it works — on the live edge and inside the Visual Studio editing canvas.

npm install @taghost/react

React 18 or newer is a peer dependency. The SDK is fully tree-shakeable (sideEffects: false).

Visual CMS

Tag any element with a data-tag attribute. TagHost's edge worker rewrites its text in-place on every request, so there is no re-render, no fetch, and no flash of unstyled content.

<h1 data-tag="hero.title">Your fallback headline</h1>
<p data-tag="hero.subtitle">Your fallback copy</p>

In the browser the fallback content is what renders; on the edge the published value replaces it. Your repo stays the source of truth in code.

Lead capture

<TagForm> posts to the edge and hands submissions to TagHost's lead pipeline, where they are routed, stored, and delivered to your notification email.

import { TagForm } from '@taghost/react';

<TagForm name="early-access" onSuccess={() => toast('Thanks!')} onError={(e) => console.error(e)}>
  {({ isSubmitting }) => (
    <button disabled={isSubmitting}>{isSubmitting ? 'Sending…' : 'Join the waitlist'}</button>
  )}
</TagForm>

name identifies the form in the dashboard. Pass onSuccess / onError to react to the result, or render a plain child element instead of a render function.

Dynamic collections

import { useTagCollection } from '@taghost/react';

const { items, isLoading, error } = useTagCollection<{ title: string }>('case-studies');

Collections are structured content (blog posts, case studies, pricing tiers) served from /_tag/collections/:name. Pass a second argument of initialItems to render from pre-fetched data and skip the initial request.

Config helper

import { defineConfig } from '@taghost/react';

export default defineConfig({
  projectId: 'proj_123',
  framework: 'vite-react',
  designTokens: { /* … */ },
});

API

| Export | Purpose | | --- | --- | | TagForm | Edge-backed lead capture form. | | useTagCollection | Fetch a dynamic collection with loading/error state. | | defineConfig | Typed taghost.config helper. | | tagBridge | The runtime bridge the canvas talks to. | | TAG_PROTOCOL_VERSION | Version of the canvas protocol. |

Zero lock-in

This SDK is a thin convenience layer. data-tag attributes are plain HTML, and every value is readable as ordinary text. If you ever want out, tag eject (from @taghost/cli) rewrites this SDK back into plain React source you own. No runtime dependency is required to host the result.

Links

  • Product: https://taghost.io
  • Docs: https://docs.taghost.io
  • Issues: https://github.com/georgennad/TagHost/issues

License

Proprietary. See LICENSE.