Gluon universal package · 1.10.0

@gluonjs/reactivity

DOM-free reactive state primitives for Gluon.

Runtimeuniversal
Version1.10.0
LicenseMIT
Public entry points3

Install and start

Install the public package at the same version as the rest of the Gluon train:

shell
npm install @gluonjs/reactivity
ts
import { computed, effect, reactive, ref } from '@gluonjs/reactivity';

const count = ref(1);
const state = reactive({ multiplier: 2 });
const total = computed(() => count.value * state.multiplier);

effect(() => {
  console.log(total.value);
});

Purpose

DOM-free reactive state primitives for Gluon.

Use cases

  • Shared reactive state in browser, Node, and SSR code.
  • Signals-style derived state and side effects.
  • Core runtime ownership for packages that depend on reactive state.

Public entry points

Only these package exports are part of the supported public boundary.

Dependencies and peers

Installed dependencies

  • None

Peer dependencies

  • @preact/signals-core@>=1.14.4 <2 · optional
  • signal-polyfill@0.2.2 · optional

API reference

Open an entry point above for generated symbol documentation and a reviewed example for every public symbol. Application code must import from this package entry point, never from repository source paths.

Scope and limits

  • Does not provide DOM, component, router, or store APIs.
  • Applications that need object lifetime, templating, or elements must use the owning package.

Related guides

Verified integration notes

  • Peer dependencies include `@preact/signals-core` and `signal-polyfill`.
  • Package manifest exports `.` plus `./signals` and `./preact-signals`.