ztools

Zero-dependencies reactive UI runtime

DOM-first. AI-ready. No framework.

See also: Philosophy

Features

Install

npm install @ztools.org/runtime

Zero-setup (single HTML file)

Copy this into index.html and open it in a browser:

<!doctype html>
<html>
  <body>
    <div id="app"></div>

    <script type="module">
      import { signal, computed, tags, mount } from "https://ztools.org/dist/ztools.client.full.js";

      const { div, p, button } = tags;

      function App() {
        const count = signal(0);
        const doubled = computed(() => count() * 2);

        return div(
          p("count: ", () => count(), " x2=", () => doubled()),
          button({ onClick: () => count.set(count() + 1) }, "+1")
        );
      }

      mount(App, document.getElementById("app"));
    </script>
  </body>
</html>

For a full project setup walkthrough, see Getting Started.

API

See full API reference: API

Examples

Examples are published here: /demo/

Source

github.com/maxistar/ztools