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

@mistriwork/search-sqlite

v1.4.2

Published

SQLite FTS5 search provider pack for mistri Apps, over Node's built-in node:sqlite with zero extra dependencies.

Readme

@mistriwork/search-sqlite

SQLite FTS5 as the search provider for a mistri App's search blocks.

What it is

Search is an index, never a source of truth. The index holds a copy of the fields a resource declares searchable, keyed by the record's primary key, and answers a phrase with keys; the rows are re-read from the database under the reader's own grants. The pack holds only what is SQLite's:

  • SqliteFtsIndex: one FTS5 table per collection in one file, on Node's built-in node:sqlite (zero extra runtime dependencies). It writes a tenant's scope as an exact match on a column, ranks by bm25 with an earlier declared field weighing more (full-text ranking: a rare word in a later field can still outrank a common word in an earlier one), and rebuilds a table when a declaration adds a field — FTS5 tables cannot be altered. Collection and field names must be word characters; anything else is refused rather than quoted.
  • sqliteSearchConnectionOf & sqliteSearch: validates connection entries and creates a SearchProvider whose close() releases open SQLite handles.

How it plugs in

Pass the provider to createHandler({ search }) from @mistriwork/mistri/handler, or plug it into a Registry with plugSearch from @mistriwork/mistri/search:

import { createHandler } from '@mistriwork/mistri/handler';
import { sqliteSearch } from '@mistriwork/search-sqlite';

const mistri = createHandler({
  config: './mistri.json',
  basePath: '/desk',
  publicOrigin: 'https://example.com',
  search: sqliteSearch([{ name: 'fts', file: './search.db' }]),
});

An App names the connection in its resource:

resources: { ticket: { search: { connection: 'fts', fields: ['subject', 'requester.name'] } } }

The file is opened on first use. :memory: holds the index in the process only, like the built-in memory provider, and suits tests; a file survives a restart, so no reindex is needed after one. ${VAR} references in file expand when the file opens.

What it is not

  • Postgres tsvector. Use @mistriwork/search-postgres when your deployment runs PostgreSQL and wants GIN-indexed tsvector tables beside its database.
  • A large catalog. FTS5 in one file suits moderate tables. A large catalog wants a dedicated engine such as Typesense.