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

nexus-jsx

v0.1.0

Published

A high-performance hybrid engine that transforms JSON schemas into fully functional React components.

Readme

🧬 Nexus-JSX

Architecture is the realization that UI = f(State + Logic)
“Don’t write the component — describe the intent.”

Nexus-JSX is a high-performance, lightweight React engine that transforms logic-infused JSON schemas into fully functional, production-ready UI modules.

It is designed as a long-term, stable foundation for Server-Driven UI (SDUI), modular frontends, and orchestration-based architectures — without sacrificing React’s hook ecosystem or runtime performance.


🏗️ The Architectural Shift

Orchestration over Construction

Nexus-JSX introduces a new development culture that replaces the traditional component-per-file mindset with Schema-Driven Orchestration.


1️⃣ End of File Inflation

Instead of creating dozens of .jsx files for pages, cards, modals, and flows, you define what the UI should do, not how it should be constructed.

The engine becomes the constant.
Schemas become the variable.


2️⃣ Lego-Style Composition

Build your UI primitives once (Inputs, Buttons, Tables, Charts).
Inject them into the Nexus engine.

Schemas orchestrate these parts into complete modules at runtime.

No duplication.
No rewiring logic.


3️⃣ True Decoupling by Design

  • UI → Defined inside the schema template
  • Business Logic → Lives in customHooks or externalContext
  • State Control → Centralized via the Bridge

Want to redesign a Product List?
Change the schema template — not Redux, not API services, not hooks.


⚡ The Nexus Advantage

| Capability | Legacy React | Nexus-JSX | |---|---|---| | UI Structure | One file per component | One engine + schemas | | Data Flow | Prop drilling / Context | Direct bridge access | | Logic Coupling | UI + logic intertwined | Fully decoupled | | Runtime Control | Fragmented | Centralized orchestration | | Performance | Re-render heavy | Turbo Engine | | Longevity | Refactor-heavy | Schema evolution |


✨ Core Features

  • Logic Injection
    Use any React hook (useFormik, useQuery, custom hooks) directly inside schemas.

  • Stable Logic Bridge
    A single, stable bridge reference for the lifetime of the component:

    • state access
    • state mutation
    • actions
    • events
    • hooks
    • injected components
  • Unified Actions API
    One action system for JSX templates and HTML templates: bridge.actions.run("actionName")

  • Turbo Engine (Default)

    • True shallow state comparison
    • Referentially stable bridge
    • Optional visibility-aware rendering
  • Lifecycle Orchestration
    onMount, onUnmount, onUpdate, and watched state paths.

  • Event Bus Built-In
    bridge.on / emit / off for cross-module communication.

  • Safety & Longevity

    • Safe Mode for untrusted schemas
    • Schema validation & dev warnings
    • SSR-aware runtime guards
  • Zero Runtime Dependencies
    Uses your existing React version via peerDependencies.


🚀 Installation

npm install nexus-jsx

🛠️ Basic Usage

Define intent via schema — Nexus assembles the component.

import NexusJSX from "nexus-jsx";

const schema = {
  name: "CounterModule",
  initialState: { count: 0 },

  template: (bridge) => (
    <div>
      <h1>Clicks: {bridge.state.count}</h1>
      <button onClick={() => bridge.merge({ count: bridge.state.count + 1 })}>
        Increment
      </button>
    </div>
  ),
};

const Counter = NexusJSX(schema);

// Use it in your App
export default function App() {
  return <Counter />;
}

🧬 Advanced Integration (Hooks & Form Logic)

Inject complex logic without coupling it to UI files.

import { useFormik } from "formik";
import * as Yup from "yup";

const Registration = NexusJSX(UserSchema, {
  components: { CustomInput, CustomButton },

  customHooks: {
    useFormik: () =>
      useFormik({
        initialValues: { email: "" },
        validationSchema: Yup.object({
          email: Yup.string().email().required(),
        }),
        onSubmit: (values) => console.log(values),
      }),
  },
});

Inside the schema template:

const formik = bridge.useFormik;

🏎️ Turbo Engine

Turbo mode is enabled by default.

It provides:

  • Shallow state comparison
  • Stable bridge reference
  • Optional CSS-level visibility optimization
  • Forced updates when explicitly required
  • Designed for dashboards, SDUI, and large dynamic UIs.

📦 Examples

Production-grade usage scenarios are provided:

  • Minimal Counter
  • Formik Registration Flow
  • Server-Driven UI (Remote Schema)
  • Dashboard Layout DSL
  • Plugin-Based UI Modules
  • Performance Stress Test (Turbo)

👉 See /examples on GitHub and /docs.

🧠 Philosophy

UI is not a file. It is a projection of state, logic, and intent.

Nexus-JSX is built to last — enabling systems that evolve through schemas, not refactors.

📄 License

MIT License

Developed by Recep Yalcin — 2026