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

@loke/icons

v1.1.0

Published

A Loke icon library package for React applications.

Readme

@loke/icons

A React icon library package inspired by lucide-react, providing tree-shakeable icon components.

Features

  • 🎨 107 carefully crafted icons
  • 🌲 Tree-shakeable - only import what you need
  • ⚡ Optimized for performance
  • 📦 TypeScript support
  • 🎯 Consistent API
  • 🔧 Customizable via props

Installation

bun add @loke/icons

Usage

Basic Usage

import { Activity, Calendar, Users } from '@loke/icons';

function App() {
  return (
    <div>
      <Activity />
      <Calendar size={32} />
      <Users color="red" strokeWidth={1.5} />
    </div>
  );
}

Available Props

All icons accept the following props:

  • size?: string | number - Icon size (default: 24)
  • color?: string - Icon color (default: "currentColor")
  • strokeWidth?: number - Stroke width (default: 2)
  • absoluteStrokeWidth?: boolean - Use absolute stroke width
  • className?: string - Additional CSS classes
  • Plus all standard SVG attributes

Custom Icons

You can create custom icons using the createLokeIcon function:

import { createLokeIcon } from '@loke/icons';
import type { IconNode } from '@loke/icons';

const customIconNode: IconNode = [
  ['path', { d: 'M10 10 L20 20' }],
  ['circle', { cx: '10', cy: '10', r: '5' }],
];

const CustomIcon = createLokeIcon('custom-icon', customIconNode);

Using the Base Icon Component

import { Icon } from '@loke/icons';
import type { IconNode } from '@loke/icons';

const iconNode: IconNode = [
  ['path', { d: 'M10 10 L20 20' }],
];

function MyComponent() {
  return <Icon iconNode={iconNode} size={24} />;
}

Available Icons

All icons are exported in PascalCase:

  • Activity
  • AlarmClock
  • AlertCircle
  • AlertTriangle
  • Archive
  • ArrowDown
  • ArrowLeft
  • ArrowRight
  • ArrowUp
  • Award
  • BarChart
  • Building2
  • Buildings
  • Calculator
  • Calendar
  • CalendarClock
  • Check
  • CheckCircle
  • ChevronDown
  • ChevronLeft
  • ChevronRight
  • ChevronUp
  • ChevronsDown
  • ChevronsLeft
  • ChevronsRight
  • ChevronsUp
  • ChevronsUpDown
  • Circle
  • CircleDollarSign
  • CircleHelp
  • CirclePlay
  • CircleX
  • Clock
  • CloudUpload
  • Code
  • Copy
  • CreditCard
  • Dollar
  • DollarSign
  • Ellipsis
  • ExternalLink
  • Eye
  • EyeOff
  • FileText
  • Filter
  • Gift
  • Globe
  • GripVertical
  • HelpCircle
  • House
  • Image
  • Info
  • Lightbulb
  • Link
  • List
  • ListFilter
  • Loader2
  • LoaderCircle
  • Lock
  • Mail
  • MapPin
  • Megaphone
  • Menu
  • MessageSquare
  • MessagesSquare
  • Minus
  • Moon
  • Package
  • Palette
  • PanelLeft
  • Pause
  • Pencil
  • Percent
  • Phone
  • PieChart
  • Play
  • Plus
  • PoundSterling
  • Puzzle
  • RefreshCw
  • Repeat
  • RotateCcw
  • Save
  • Search
  • Settings
  • ShoppingBag
  • SlidersHorizontal
  • Smile
  • SortAsc
  • SortDesc
  • Star
  • Sun
  • Tag
  • Ticket
  • Trash
  • TrendingDown
  • TrendingUp
  • Unlink
  • User
  • UserCog
  • Users
  • Utensils
  • Webhook
  • Wifi
  • WifiOff
  • WrapText
  • X

Icon Metadata

The src/meta/ directory contains metadata for each icon:

  • .json files: Icon metadata including tags, categories, and aliases. These are used for icon search, filtering, documentation, and creating alternative import names. Each JSON file contains:

    {
      "tags": [],       // Keywords for searching/filtering icons
      "categories": [], // Icon categories for organization
      "aliases": []     // Alternative names for importing this icon (optional)
    }
  • .svg files: Original source SVG files in kebab-case format. These are the source files used during the build process to generate the React components.

These metadata files are kept in the repository for development purposes but are not included in the published npm package (only the compiled dist directory is published).

Icon Aliases

Aliases allow you to import icons using alternative names. This is useful for:

  • Providing backwards compatibility when renaming icons
  • Offering multiple naming conventions (e.g., US vs UK spelling)
  • Supporting common alternative names for the same icon

Adding Aliases

Add aliases to an icon's JSON metadata file:

{
  "tags": ["search", "find"],
  "categories": ["ui"],
  "aliases": [
    {
      "name": "SearchIcon"
    },
    {
      "name": "Find",
      "deprecated": true,
      "deprecationReason": "Use Search instead",
      "toBeRemovedInVersion": "1.0.0"
    }
  ]
}

Using Aliases

Once defined, you can import icons using their alias names:

import { SearchIcon, Find } from '@loke/icons';

// Both import the same 'search' icon
<SearchIcon />
<Find />  // Shows deprecation warning in IDE

Deprecation

Mark aliases as deprecated to guide users away from old names:

  • deprecated: Set to true to mark the alias as deprecated
  • deprecationReason: Optional message explaining why it's deprecated
  • toBeRemovedInVersion: Optional version number when the alias will be removed

Deprecated aliases will show warnings in TypeScript-enabled editors via JSDoc comments.

Development

Generating Icons

bun run gen

Run this when adding or updating SVG icons. This will:

  1. Read SVG files from src/meta/
  2. Convert names from PascalCase to kebab-case
  3. Generate TypeScript components in src/icons/
  4. Create JSON metadata files (if they don't exist)
  5. Generate the main index file and aliases
  6. Format the generated code

The generated source files are committed to the repo.

Building

bun run build

This compiles the package for distribution:

  1. Clean the dist directory
  2. Bundle JavaScript with Bun (ESM with "use client" directive)
  3. Generate TypeScript declarations

Type Checking

bun run typecheck

Cleaning

bun run clean

This removes the dist directory.

License

ISC