@fiberfx/core
v4.1.1
Published
Mercury foundation — the UI-free layer: class utility, shared types, headless hooks, and locale-aware date formatters. No components, no styles.
Readme
@fiberfx/core
The UI-free foundation of the Mercury design system: a class utility (cx),
locale-aware date formatters, headless behaviour hooks, and the shared type kit.
No UI components or styles; no React dependency.
@fiberfx/ui declares this package
as a peer. Install it explicitly for a UI consumer, or use it directly for
the utilities without UI styles.
Install
npm install @fiberfx/[email protected] @fiberfx/[email protected]Version 4.0.0 declares @fiberfx/[email protected] as its only peer.
For an existing mx app, preserve mx.mod and mx.sum and use mx install.
Use
import { cx, createFormatter } from "@fiberfx/core";
cx("btn", isActive && "btn--active"); // conditional classNames
const fmt = createFormatter({ locale: "en-US" }); // locale-aware Intl wrapperShips as a single ES-module bundle (dist/index.js) with type
declarations. @fiberfx/hyperscript is external as a peer; there is no React
peer and no dependencies entry. The date module is in src/internal/date/.
License
MIT
