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

touchpoints-wc

v0.3.0

Published

TypeScript Web Components with Form Submission

Readme

touchpoints-wc

A TypeScript web component built with Lit for collecting yes/no feedback using Touchpoints forms. Features accessible design following USWDS standards with built-in icons and customizable styling.

Installation

npm install touchpoints-wc

Usage

Import and use the component in your HTML:

<touchpoints-yesno form-id="your-form-id"></touchpoints-yesno>

Or import in JavaScript/TypeScript:

import 'touchpoints-wc';

// Component is now available as <touchpoints-yesno>

Features

  • Accessible: WCAG compliant with proper focus management and ARIA attributes
  • Customizable: Override icons and labels via attributes or slots
  • Responsive: Works on all screen sizes
  • TypeScript: Full TypeScript support with type definitions
  • Lightweight: ~6KB gzipped, no external dependencies except Lit
  • Shadow DOM: Encapsulated styling prevents CSS conflicts

Attributes

| Attribute | Type | Default | Description | |-----------|------|---------|-------------| | form-id | string | required | The ID of the Touchpoints form to submit feedback to | | yes-label | string | "Yes" | Custom label for the positive feedback button | | no-label | string | "No" | Custom label for the negative feedback button |

Slots

You can customize the icons by providing your own content in these slots:

<touchpoints-yesno form-id="abc123">
  <svg slot="yes-icon" width="20" height="20"><!-- custom yes icon --></svg>
  <svg slot="no-icon" width="20" height="20"><!-- custom no icon --></svg>
</touchpoints-yesno>

Examples

Basic Usage

<touchpoints-yesno form-id="feedback-form-123"></touchpoints-yesno>

Custom Labels

<touchpoints-yesno 
  form-id="abc123" 
  yes-label="Helpful" 
  no-label="Not helpful">
</touchpoints-yesno>

Custom Icons

<touchpoints-yesno form-id="abc123">
  <span slot="yes-icon">👍</span>
  <span slot="no-icon">👎</span>
</touchpoints-yesno>

Development

# Install dependencies
pnpm install

# Development mode with hot reload
pnpm dev

# Build for production
pnpm build

# Lint package for npm publishing
pnpm publint

Release Management

This project uses Changesets for version management and publishing. Changesets help maintain semantic versioning and generate changelogs automatically.

Creating a Changeset

When you make changes that should trigger a release, create a changeset:

# Create a new changeset
pnpm changeset

This will prompt you to:

  1. Select which packages have changed (for monorepos)
  2. Choose the type of change:
    • patch: Bug fixes, small improvements
    • minor: New features, backwards compatible changes
    • major: Breaking changes
  3. Write a summary of the changes

Release Process

The release process is automated via GitHub Actions:

  1. During Development: Create changesets for your changes
  2. Release PR: When changesets are merged to main, a "Release PR" is automatically created
  3. Publishing: Merging the Release PR will:
    • Update versions in package.json
    • Generate/update CHANGELOG.md
    • Create a GitHub release
    • Publish to npm

Manual Release Commands

For manual releases or testing:

# Update package versions based on changesets
pnpm changeset:version

# Build and publish to npm
pnpm changeset:publish

Technical Details

  • Built with Lit for reactive web components
  • Styled with UnoCSS using USWDS design system
  • Compiled with tsdown for optimal bundle size
  • Type definitions included for TypeScript projects