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

@latty-ds/icons

v0.6.0

Published

Icon components for the Latty design system — pluggable icon registry with Iconoir as the default provider

Readme

@latty-ds/icons

Icon system for the Latty Design System. Ships a curated set of pre-registered icons from Iconoir and a pluggable provider registry for adding your own.

See the icon gallery in the docs for the full list of available icons.

Installation

pnpm add @latty-ds/icons

Basic usage

<lt-icon name="check"></lt-icon>
<lt-icon name="arrow-right" size="lg"></lt-icon>
<lt-icon name="search" size="sm"></lt-icon>

Icons inherit currentColor, so color them with CSS:

<lt-icon name="check" style="color: var(--lt-color-success-500)"></lt-icon>

Sizes

xs (12px) · sm (16px) · md (20px, default) · lg (24px) · xl (32px)

Registering custom icons

import { iconRegistry } from '@latty-ds/icons';

// Single icon
iconRegistry.registerIcon('my-icon', '<svg>...</svg>');

// Multiple at once
iconRegistry.registerIcons({
  'icon-a': '<svg>...</svg>',
  'icon-b': '<svg>...</svg>'
});

Custom icons take priority over provider icons, so you can override any default:

iconRegistry.registerIcon('check', '<svg><!-- your custom check --></svg>');

Custom providers

import { iconRegistry } from '@latty-ds/icons';
import type { IconProvider } from '@latty-ds/icons';

class MyProvider implements IconProvider {
  name = 'my-provider';
  private icons = new Map([['icon-1', '<svg>...</svg>']]);

  getIcon(name: string) {
    return this.icons.get(name);
  }

  getAllIcons() {
    return new Map(this.icons);
  }
}

iconRegistry.registerProvider(new MyProvider());

Using icons inside components

Components that accept icons use icon / icon-end / icon-start props:

<lt-button icon="save">Save</lt-button>
<lt-button icon-end="arrow-right">Next</lt-button>
<lt-textfield icon-start="search" placeholder="Search…"></lt-textfield>

API reference

iconRegistry

| Method | Description | | ---------------------------------------- | --------------------------------------- | | registerProvider(provider, isDefault?) | Register an icon provider | | registerIcon(name, svg) | Register a single icon | | registerIcons(icons) | Register multiple icons | | getIcon(name) | Get an icon SVG string by name | | hasIcon(name) | Check if an icon is registered | | getAvailableIcons() | Get all registered icon names | | setDefaultProvider(name) | Change the active default provider | | clearCustomIcons() | Remove all manually registered icons | | reset() | Reset the registry to its initial state |

IconProvider interface

interface IconProvider {
  name: string;
  getIcon(name: string): string | undefined;
  getAllIcons(): Map<string, string>;
}

License

MIT