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

@seij/entity-storage

v0.1.2

Published

Runtime storage layer for entity instances, designed to pair with `entity-graph`. While `entity-graph` describes _what_ exists (entities, properties, relationships), `entity-storage` defines _how_ to fetch, search, create, update, and delete the actual da

Readme

entity-storage

Runtime storage layer for entity instances, designed to pair with entity-graph. While entity-graph describes what exists (entities, properties, relationships), entity-storage defines how to fetch, search, create, update, and delete the actual data.

What it provides

  • A contribution-based registry for entity storage implementations.
  • A single service (EntityStorageService) to route CRUD operations by entity name.
  • DTOs for list, pagination, and single-item responses.
  • Query key helpers to support cache invalidation (e.g., React Query).
  • Optional mapping helpers for aggregate fetch results.

What it is (and how it differs from usual approaches)

Most applications hardcode a repository or API client per entity, tied to a single backend and a fixed schema. This module is different: it routes data access by entityName at runtime, using contributions that can come from multiple bounded contexts. That makes it a storage platform rather than a collection of static services.

The real power comes from its link to entity-graph: the graph tells the UI what entities exist and how they relate; the storage tells the UI where to fetch and mutate the data. Together, they turn a dynamic domain model into a working dynamic UI without hardcoding endpoints or per-entity services.

Concrete outcomes: fewer per-entity repositories, consistent data access across domains, and faster delivery of baseline screens (lists, detail, edit).

Why it matters

  • Separates model discovery (entity-graph) from data access (entity-storage).
  • Lets multiple backends or storage strategies coexist behind one API.
  • Enables dynamic UI to load and mutate entity data without hardcoding endpoints.
  • Provides consistent cache keys and invalidation hooks across entities.

How it works

  • Extensions contribute a storage implementation per entity name.
  • The storage exposes fetchItem, search, createItem, updateItemProperty, and deleteItem.
  • The service resolves the right store by entity name and forwards calls.
  • Additional invalidation keys can be contributed for cross-query consistency.