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

letant

v0.0.2

Published

AST based language-agnostic structural code comprehension

Readme

L'étant

L'étant is a short for les étant, meaning "The Beings" in French.

License: MIT

Provide a clear provenance map, trimming out noises for comprehension.

About

A structural code comprehension tool. letant parses source files using Tree-Sitter, extracts every scope boundary and name binding, construct a queryable definition graph, provide provenance map of given position.

A Different Question

Every other tool in this space asks "where is this symbol and who uses it?" — a cartographic question that requires mapping everything. L'étant asks "where did this come from?" — a genealogical question that requires only following the lineage of what you're looking at.

This follows the natural direction of code comprehension. When you read code, you encounter a symbol and look up where it came from. L'étant only traces forward: from usage to origin.

Architecture

Data Model

All output is two types:

  • Node — a code entity with a path segments, hashed to a compact NodeId inside the graph. A kind classifies the entity, a type role classifies its scope behavior.
  • Edge — a directed relationship between two nodes (fromto)

Node Roles

Every node has a type field with one of three values:

| type | Description | Example kind values | | ------ | ----------- | --------------------- | | "scope" | A named scope — introduces names and is itself introduced into a parent scope | function, class, method, ... | | "anonymous" | An unnamed scope — introduces names but has no binding identity of its own | iife, if, for, while, ... | | "binding" | A pure binding — is introduced into a scope, does not introduce names | variable, member, import, parameter, ... |

Responsibilities

L'étant separates concerns across three layers:

Language plugin — interprets the raw Tree-Sitter AST for a specific language. Faithfully extracts every entity the parser exposes and maps it to the common node/edge schema. Two phases:

  • capture — runs tree-sitter queries against AST nodes and returns typed match results. Decides what entity to capture from the source.
  • convert — transforms captures into graph nodes and edges. Decides how the entities relate, and provides opinionated result.

Core — constructs a queryable graph based on the converted result from plugin, and provides navigable interface on top of it.

Prerequisites

  • Node.js 22+ — Node 22 uses prebuilt Tree-Sitter binaries. Node 24 and 25 build from source and additionally require python3, make, and g++ with C++20 support.
  • pnpm — workspace manager.
  • On Node 24/25, set CXXFLAGS="-std=c++20" before installing.

Usage

# Install dependencies (Node 24/25: prefix with CXXFLAGS="-std=c++20")
pnpm install

# Build core
pnpm build

# Build all packages
pnpm build:all

# Type check everything
pnpm check-types:all

# Run CLI against mock data
pnpm dev:config

# Lint
pnpm lint

# Tests
pnpm test

License

MIT