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

@genrojs/builders

v0.4.2

Published

Grammar-driven builders: typed Source trees from JSON grammars, for any dialect, with pluggable renderers.

Readme

genro-builders-js

Build typed Source trees from JSON grammars and render static HTML, SVG or XML. The generic renderer also supports dialect-defined object output. This package has no DOM, browser subscriptions, server or database dependencies.

Version 0.4.1 is published on npm and JSR with the Bag 0.10 contract. Python parity is bounded by documented differences. Recipes are not implemented. A builder declares the SourceBag class of its Source in static _sourceClass (Source class).

import { HtmlBuilder } from '@genro/builders';

const page = new HtmlBuilder();
page.data.setItem('price', 1234.5);
const body = page.root.html().body();
body.h1('Hello');
body.div('^price', {format: '#,##0.00', locale: 'it-IT', mask: '€ %s'});
const html = page.render();

Install and verify

The same package is published on two registries:

  • npm: npm install @genrojs/builders, then import from @genrojs/builders;
  • JSR: npx jsr add @genro/builders (or bunx jsr add), then import from @genro/builders.

From a local checkout, run npm ci and npm test. Node.js 22 or later and Bun are the supported server runtimes. First-party dependencies use compatible caret ranges; the committed package-lock.json fixes the versions CI installs. The source imports Bag and TYTX as @genrojs/bag and @genrojs/tytx, the npm names; jsr.json maps them to jsr:@genro/bag and jsr:@genro/tytx. Each registry's package therefore depends on one Bag class and one TYTX registry instance from the same registry.

Deno publication keeps a 24-hour cooldown for external dependencies and exempts jsr:@genro/* and npm:@genrojs/* to permit verified sequential releases.

Documentation

Build the Sphinx manual locally:

python -m pip install -r docs/requirements.txt
python -m sphinx -W --keep-going -n -b html docs build/docs

The manual uses the classic Read the Docs theme. No hosting is configured or implied. See CHANGELOG for the local version change.

Copyright 2025–2026 Softwell S.r.l. Apache-2.0; see LICENSE and NOTICE.

Attribute templates and raw HTML (2026-09-21)

${name} interpolation applies only to attributes. A preceding backslash, \${name}, produces literal ${name} without looking up or consuming name. Use a raw string or escape the backslash in the authoring language. Node values never interpolate template tokens; Data pointers and resolvers still resolve normally. This preserves JavaScript template literals in script content.

For HTML output, a node value ending in ::HTML emits raw markup and drops the suffix. Ordinary text remains escaped. This marker does not enable templates, does not sanitize markup and does not change attribute escaping. For example, <b>${name}</b>::HTML emits <b>${name}</b> literally.