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

@dendrite-lang/core

v0.8.2

Published

A declarative dataflow language with incremental reactive evaluation, embeddable in TypeScript.

Downloads

1,563

Readme

@dendrite-lang/core

A declarative dataflow language you embed in a TypeScript application.

A program is a set of named values and outputs. Your application declares what programs may read and must produce, pushes values in, and acts on what comes out. When an input changes, only what depends on it recomputes. Programs are type-checked before they run, and every program terminates.

📖 Documentation · 🧪 Playground

Install

npm install @dendrite-lang/core

ESM and CommonJS, with types. One runtime dependency, zod.

A program, running

import {
  createEnvironment,
  createStdlib,
  Policy,
  serialiseSource,
  Type,
} from "@dendrite-lang/core";

const env = createEnvironment(createStdlib());

// Your contract: what every program on this runtime may read and must produce.
const runtime = env.createRuntime({
  layers: [
    {
      id: "host",
      policy: Policy.host,
      ports: {
        inputs: [{ name: "temperature", type: Type.number, default: 20 }],
        outputs: [{ name: "alert", type: Type.boolean, mode: "required" }],
      },
    },
  ],
});

// One program, running.
const instance = env.createInstance(runtime, {
  program: serialiseSource("output alert = $temperature > 25"),
});

instance.outputs.subscribe(({ outputs, stale }) => console.log(outputs?.get("alert"), { stale }));
runtime.setInputs({ temperature: 30 }); // true

What is in the box

  • The language: a parser, an analyser that resolves types and checks every op call, and a pull-based evaluator that recomputes only what an input change reaches.
  • A standard library of logic, control, array, arithmetic, list, conversion and string ops, with symbols as sugar over them. createStdlib({ segments: ["logic", "arithmetic"] }) takes part of it.
  • Port layers: a language declares no inputs or outputs; your application does, in layers whose order is authority.
  • An instance to hold: five observables and five commands. A program that stops compiling keeps its last good outputs, marked stale rather than hidden.
  • Extension: register your own types, ops, evaluators and operators.
  • Every diagnostic documented: diagnostics is the registry of all of them, each with a program that triggers it.

Where to go next

Pre-1.0: the API can still change between minor versions.

Related packages

License

MPL-2.0