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

@sarimarcus/content-sites-core

v0.29.2

Published

Non-visual utilities, Astro config builders and SEO schema assembly shared by the content sites.

Readme

@sarimarcus/content-sites-core

Non-visual code shared by the content sites: generic utilities, Astro config builders, SEO schema assembly, and the type contracts ui and tourism build on (for example the card item and tag-link shapes that today's ui components import from tourism code).

Named entry points: url, affiliate, dates, geo, dom, text, config, types, schema, interludes, images and articles (src/internal is never exported). No .astro files. Lowest layer: imports nothing from the other packages; its one runtime dependency is marked (readingTime). Ownership per path is in .planning/platform/catalogue.json (owner core).

Code Node loads directly (config builders imported by astro.config.mjs) ships compiled to dist/ with type declarations. Node will not strip types from files under node_modules. So every entry point resolves to dist/: npm run build -w packages/core compiles it (tsconfig.build.json), and release-check.mjs refuses a missing or stale dist/.

Core code never imports astro:content, never reads import.meta.env or import.meta.glob (values and glob results come in as parameters), and never names a site or vertical. validate-packages.mjs enforces all three.

schema assembles a page's JSON-LD graph: createSchemaContext (site URL, base path, page path, and the site's author lookup, public-file check, markdown stripper, publisher policy and route map), assembleGraph (base nodes, breadcrumb, then each entry's builder in call order, with hooks before and after the entries) and finalizeGraph. Builders are factories whose options carry each site's differences, so a site reproduces its current output byte for byte, key order included. It also holds the opening-hours model (generateOpeningHours, parseHoursString, assertedOpenDays, hoursStringOpenDays) that scripts/validate-opening-hours.mjs imports. The factory scripts load dist/; scripts/lib/core-dist.mjs rebuilds it when it is missing or older than src/.

images holds the one responsive width ladder (IMAGE_LADDER: 160, 240, 320, 480, 640, 960, 1280; WebP only) and the image service defineSiteConfig installs. The service never encodes: it serves committed variants from the site's image-variants/ (keyed by the source's content hash, listed in manifest.json) and the source bytes for the native width, and caps each srcset at the source width. A call site asks for a responsive image with widths={IMAGE_LADDER} plus sizes, which ui's ResponsiveImage / ResponsivePicture pass for it; images without variants (galleries) get a single src and no srcset. content-sites-image-variants (bin, npm run images:variants in a site) writes missing variants with sharp, an optional peer, and prunes unused ones; --check is the local form of the push gate scripts/validate-image-variants.mjs.