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

@echojs-ecosystem/hyperdom

v0.10.0

Published

Readme

@echojs-ecosystem/hyperdom

Direct DOM rendering — no virtual DOM, no JSX required.

npm docs


The view layer of EchoJS. Maps views to real DOM nodes with a hyperscript API (h), reactive children, and control helpers (Show, List). Designed as the foundation for a future JSX compiler.

Features

  • h() — create elements, components, and reactive regions
  • createView / createModel — structured UI with context checks
  • Show / If / List — conditional and list rendering
  • Reactive props & children() => value registers effects; only what changed updates
  • render() + dispose() — mount with full cleanup (listeners, effects, DOM)

Install

npm install @echojs-ecosystem/hyperdom @echojs-ecosystem/reactivity

Quick start

import { h, render, Show, button, div, span } from "@echojs-ecosystem/hyperdom";
import { signal } from "@echojs-ecosystem/reactivity";

const $count = signal(0);

const view = div({ class: "app" }, [
  button({ onClick: () => $count.update((n) => n + 1) }, "Increment"),
  span(null, () => String($count.value())),
  Show(
    () => $count.value() > 0,
    () => span(null, "Count is positive"),
  ),
]);

const dispose = render(view, document.getElementById("app")!);
// dispose() when unmounting

API

| Export | Description | |--------|-------------| | h, div, button, … | Hyperscript & HTML DSL | | render(view, container) | Mount view, return dispose() | | createView / createModel | View/model factories | | createComponent | Model + view composition | | mount | Mount view tree into a DOM container | | Show | Boolean toggle (display: none) | | effect | Model lifecycle — reactive side effects | | If(cond, render).IfElse().Else() | If / else-if / else with explicit conditions | | Match().When().Otherwise() | Pattern matching on objects |

Package layout

src/
  core/           types, config, view-context
  hyperscript/    h()
  dsl/            div, button, span, …
  render/         render(), mount()
  view/           createView
  model/          createModel
  lifecycle/      effect (model), render scopes (cleanup)
  component/      createComponent, createAsyncComponent
  compound/       createCompoundView (slots)
  control/        Show, If, List, Match
  dom/            DOM mount engine (internal)

Reactive patterns

// Reactive child
h("span", null, () => $count.value());

// Reactive prop
h("input", { value: () => $text.value(), onInput: (e) => $text.set(e.currentTarget.value) });

Related packages

| Package | Role | |---------|------| | @echojs-ecosystem/reactivity | Signals for dynamic regions | | @echojs-ecosystem/router | SPA routing bindings | | @echojs-ecosystem/ui | Accessible UI components |

Documentation

echojs.dev/docs/packages/hyperdom