# starfx

> A micro-mvc framework for react apps

Latest version **0.16.1** (published 2026-06-15) · MIT license · 0 weekly downloads

## Install

```sh
npm install starfx
pnpm add starfx
yarn add starfx
bun add starfx
```

## Health

**Score 75/100 (B)** — status: active.

Positive: has types; esm support; no vulnerabilities; has provenance; recently updated; high maintenance score; high quality score.

Warnings: low downloads; pre 1.0.

## Facts

| | |
|---|---|
| Version | 0.16.1 |
| Published | 2026-06-15 |
| First published | 2023-05-20 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 3 |
| Unpacked size | 436.5 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Provenance | attested (GitHub Actions) |
| GitHub stars | 126 |
| Maintainers | neurosnap, jbolda |

## Links

- npm: https://www.npmjs.com/package/starfx
- Repository: https://github.com/fxforge/starfx
- Homepage: https://github.com/fxforge/starfx#readme
- Issues: https://github.com/fxforge/starfx/issues
- npm.io page: https://npm.io/package/starfx

## Dependencies (3)

- [immer](https://npm.io/package/immer.md) ^11.1.3
- [reselect](https://npm.io/package/reselect.md) ^5.1.1
- [effection](https://npm.io/package/effection.md) ^4

## Recent versions

- 0.16.1 (latest) — 2026-06-15
- 0.16.0 — 2026-03-24
- 0.15.0 — 2025-09-05
- 0.14.6 — 2025-07-08
- 0.14.4 — 2025-06-06
- 0.14.2 — 2025-06-06
- 0.13.4 — 2024-11-17
- 0.13.3 — 2024-10-02
- 0.13.2 — 2024-08-16
- 0.13.1 — 2024-08-14
- 0.13.0 — 2024-07-30
- 0.12.0 — 2024-05-07
- 0.11.0 — 2024-04-15
- 0.10.0 — 2024-03-05
- 0.9.0 — 2024-03-04
- … 57 more at https://npm.io/package/starfx/versions

## README

![starfx](./docs/static/logo.svg)

# starfx

A micro-mvc framework for react apps.

If we think in terms of MVC, if `react` is the **View**, then `starfx` is the
**Model** and **Controller**.

[Get started](https://starfx.bower.sh)

Features:

- A powerful middleware system to fetch API data
- An immutable and reactive data store
- A task tree side-effect system for handling complex business logic using
  structured concurrency
- React integration

```tsx
import { createApi, createSchema, createStore, mdw, timer } from "starfx";
import { Provider, useCache } from "starfx/react";

const [schema, initialState] = createSchema();
const store = createStore({ initialState });

const api = createApi();
// mdw = middleware
api.use(mdw.api({ schema }));
api.use(api.routes());
api.use(mdw.fetch({ baseUrl: "https://api.github.com" }));

const fetchRepo = api.get(
  "/repos/neurosnap/starfx",
  { supervisor: timer() },
  api.cache()
);

store.run(api.register);

function App() {
  return (
    <Provider schema={schema} store={store}>
      <Example />
    </Provider>
  );
}

function Example() {
  const { isInitialLoading, isError, message, data } = useCache(fetchRepo());

  if (isInitialLoading) return "Loading ...";

  if (isError) return `An error has occurred: ${message}`;

  return (
    <div>
      <h1>{data.name}</h1>
      <p>{data.description}</p>
      <strong>👀 {data.subscribers_count}</strong>{" "}
      <strong>✨ {data.stargazers_count}</strong>{" "}
      <strong>🍴 {data.forks_count}</strong>
    </div>
  );
}
```

---
_Source: https://npm.io/package/starfx · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
