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

@texo-ui/react

v0.2.0

Published

React renderer for Texo: reconciles a streaming UI tree into your components.

Readme

@texo-ui/react

The React renderer for Texo: a streaming UI tree, reconciled into components you own.

You define the components; the model only invokes them

This is the line Texo draws, and everything about this package follows from it.

An agent that writes JSX writes new UI — new spacing, new colours, new interaction patterns, invented on the spot and inconsistent with the last screen it produced. An agent that emits Texo directives can only name things that already exist in your registry. It chooses arrangement and content. It cannot choose implementation.

import { TexoRenderer } from '@texo-ui/react';
import { createBuiltInComponents } from '@texo-ui/kit';

const registry = {
  ...createBuiltInComponents(),
  'invoice-card': InvoiceCard, // your component, your rules
};

<TexoRenderer content={stream} registry={registry} onAction={handleAction} />

A directive naming something absent from the registry does not crash and does not silently vanish — it falls through to your fallback. The failure is visible and contained.

Rendering is bidirectional

A generated screen that can only be looked at is a picture. Texo components dispatch actions, and onAction hands them back to you as structured payloads:

{ "type": "open-breakdown", "directive": "button",
  "value": { "label": "Open full breakdown", "action": "open-breakdown" } }

Feed that to the model and the conversation continues with the user's click as a turn in it. The UI is part of the loop, not the end of it.

Layout is the reconciler's job, not a component's

grid is handled by the reconciler itself rather than resolved through the registry, because a layout container has to own cell geometry and the mount protocol before any child can be placed. Directives declare where they mount (mount: "board:1:2") and the reconciler resolves that against the grid it built. Re-emitting a directive with an id it has used before replaces it in place, so a model can revise a screen mid-conversation instead of appending a second copy of it.

theme is handled the same way: it sets CSS custom properties on a scope and renders nothing of its own. Both are exported as LAYOUT_DIRECTIVES and CONTROL_DIRECTIVES so tooling can tell them apart from registry components.

Streaming is the normal case

useTexoStream and TexoRenderer treat a partial tree as valid. Directives still arriving carry status: 'streaming'; malformed ones surface through onError while the rest of the document keeps rendering. There is no state in which the screen is blank because the response is not finished.

Install

npm install @texo-ui/react @texo-ui/kit

Requires React 18 or 19 as a peer dependency.

MIT © Youngjune Kwon