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

nodality

v1.0.143

Published

A lightweight library for declarative UI elements.

Readme

Nodality

This library works with elements represented as an array of HTML entities, and nodes that control the behavior of elements.
Elements is an array of objects. This array produces the code of elements you can use in your website.
Nodes is another array containing nodes that change the look and behavior of the generated elements.

Installation

The easiest way to get up and running is to use npm:

npm create nodality@latest my-app

Tutorial

Step 1

Define an array of elements you want to display in your user interface:

let elements = [
  {
    type: "h1",
    text: "Hello"
  }
];

Step 2

Define an array of nodes that will adjust the behaviour of the element.
This particular node will add the stroked text effect:

let nodes = [
  {
    op: "blast"
  }
];

Step 3

Add the nodes array using the .nodes() modifier, and use the .set() method to mount the result of the code to the website.
Use the code: true option to also display the source code of the elements:

new Des()
  .nodes(nodes)
  .add(elements)
  .set({
    mount: "#mount",
    code: true
  });

Also define a <div> with id="#mount" that will serve as a root element to render the UI.


Everything Together

Here is the complete working code which uses CDN for convenient testing.


<!-- div for mounting the result -->
<div id="#mount"></div>

<script type="module">
import {Des} from "https://www.unpkg.com/[email protected]/dist/index.esm.js";

let elements = [
  {
    type: "h1",
    text: "Hello"
  }
];

let nodes = [
  {
    op: "blast"
  }
];

new Des()
  .nodes(nodes)
  .add(elements)
  .set({
    mount: "#mount",
    code: true
  });
</script>

Result

After running this code:

  • You will see an <h1> element on the screen.
  • When the user resizes the window and hits the 400–600px breakpoint, a stroke effect will appear on the text, thanks to the blast modifier.
  • The resulting code of the UI will also be displayed below the rendered element.