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

@neabyte/fuzzy-finder

v0.1.0

Published

High-performance fuzzy file search with intelligent ranking algorithm

Readme

Fuzzy Finder

Deno JSR npm CI License

High-performance fuzzy file search with intelligent ranking algorithm

Zero-dependency fuzzy matching engine optimized for lightning-fast file path searches. Uses bit-mask pre-filtering and intelligent scoring to deliver sub-millisecond results on massive file lists.

Features

  • Bit-Mask Pre-Filtering - Skip 90%+ of paths using 26-bit character bitmaps
  • Intelligent Scoring - Boundary, camelCase, and consecutive match bonuses
  • Case-Sensitive Mode - Auto-detects uppercase queries for precise matching
  • Async Loading - Chunked indexing for non-blocking large file lists
  • Top-N Optimization - Maintains sorted results without full sorting overhead
  • Test File Deprioritization - Auto-lower scores for test/spec files
  • Zero Dependencies - Pure TypeScript with no external dependencies
  • Universal Runtime - Works in Deno, Node.js, and browsers via CDN

Installation

[!NOTE] Prerequisites: Deno 2.0+ or Node.js 22+.

Deno (JSR)

deno add jsr:@neabyte/fuzzy-finder

npm/Node.js

npm install @neabyte/fuzzy-finder

CDN (Browser/ESM)

// esm.sh
import FuzzyFinder from 'https://esm.sh/jsr/@neabyte/fuzzy-finder'

// or unpkg (npm mirror)
import FuzzyFinder from 'https://unpkg.com/@neabyte/fuzzy-finder@latest/src/index.ts'

Quick Start

1. Import Module

// Default import (works in Deno, Node.js, and browsers)
import FuzzyFinder from '@neabyte/fuzzy-finder'

// or named export
import { FuzzyFinder, type SearchResult } from '@neabyte/fuzzy-finder'

2. Load & Search

// Initialize
const finder = new FuzzyFinder()

// Load file paths (sync)
finder.load([
  'src/index.ts',
  'src/utils/helpers.ts',
  'src/components/Button.tsx',
  'tests/index.test.ts'
])

// Search with fuzzy matching
const results = finder.search('idx', 5)
// [{ path: 'src/index.ts', score: 0.98 }, ...]

3. Async Loading (Large Lists)

const finder = new FuzzyFinder()

// Load 100k+ files without blocking UI
const { queryable, done } = finder.loadAsync(massiveFileList)

// Wait for first chunk (queryable)
await queryable

// Search while still indexing
const results = finder.search('component', 10)

// Wait for complete indexing
await done

Search Options

Include Match Positions

const results = finder.search('btn', 5, { includePositions: true })
// [{
//   path: 'src/components/Button.tsx',
//   score: 0.95,
//   positions: [17, 21, 25]  // Character indices of 'b', 't', 'n'
// }]

Case-Sensitive Search

// Uppercase in query triggers case-sensitive mode
const results = finder.search('Button', 5) // Case-sensitive
const results = finder.search('button', 5) // Case-insensitive

Build & Test

From the repo root (requires Deno).

Check - format, lint, and typecheck:

# Format, lint, and typecheck source
deno task check

Test - run tests:

# Run tests in tests/
deno task test

Purpose & Usage

Fuzzy Finder implements bit-mask accelerated fuzzy matching inspired by command palette search in editors like VS Code and Sublime Text. It pre-filters paths using 26-bit character bitmaps (one bit per a-z letter), skipping paths that cannot possibly match before running the full fuzzy algorithm.

Common use cases:

  • Command Palette - Quick file navigation in code editors
  • IDE Search - Ctrl+P style file jumping
  • CLI Tools - Fuzzy file picker for terminal applications
  • Large Dataset Filtering - Search massive file trees efficiently
  • Browser Applications - Client-side file search via CDN

See full documentation for advanced usage including:

  • Custom scoring configuration
  • Batch search operations
  • Memory optimization strategies
  • Browser integration patterns

Contributing

License

This project is licensed under the MIT license. See LICENSE for details.