Define reactive UI with plain classes. When properties change, your components will too.
Documentation · Playground · Discord
Expressive puts application state, behavior, and lifecycle in plain classes. Class fields are reactive, getters are computed, methods are auto-bound, and UI components subscribe only to the values they read.
npm install @expressive/mvc @expressive/reactimport { Component } from '@expressive/mvc';
class Counter extends Component {
count = 0;
increment() {
this.count++;
}
decrement() {
this.count--;
}
render() {
const { count, increment, decrement } = this;
return (
<div>
<button onClick={decrement}>-</button>
<span>{count}</span>
<button onClick={increment}>+</button>
</div>
);
}
}No reducers, selectors, dependency arrays, or action wrappers. Update a property and every consumer that reads it updates automatically.
The adapter is renderer-agnostic, so the same install covers React Native and Expo - exercised on an iOS simulator and an Android emulator in both Debug and Release builds (Expo SDK 57, React Native 0.86) and gated per release on Metro resolution and a Hermes build. See React Native for the three boundaries.
Continue with Getting Started, explore the guides, or browse the API reference.
| Package | Description |
|---|---|
@expressive/mvc |
Framework-agnostic reactive core: Model, Component, instructions, context. A peer dependency of every adapter - install it alongside one. |
@expressive/react |
React adapter. Registers the host - import it once from the entry. Also covers React Native and Expo. |
@expressive/dom |
MVC-native browser renderer with no React underneath - same core and router, native events, built-in styling. Early 0.x; expect change. |
@expressive/jsx |
Base JSX host: the reconciler, style engine and JSX runtime that @expressive/dom builds on. For writing a host or a library that renders under any host - apps install a host instead. |
@expressive/router |
Host-agnostic router built on Expressive components, for the React adapter and the DOM renderer alike. |
@expressive/inspect |
Dev-only in-process inspector: registry, ownership tree, path queries, and a frame journal for tests, browser drivers, and agents. |
@expressive/steps |
Multi-step processes as Models: every method a step, with undo, waits, retries and concurrency gates, and the instance awaitable for its result. In-process; early 0.x. |
All packages are pre-1.0 under one discipline: breaking changes land only in minor versions, each documented by a changeset in the package's CHANGELOG - patch releases are always safe to take.
- Why classes?
- Design decisions
- Migrating from hooks
- Comparisons with other state libraries
- Live examples
- Using Expressive with a coding agent
This repository is a Bun workspace. To get started:
bun install
bun run test
bun run buildSee AGENTS.md for repository conventions and .github/RELEASING.md for the release process.