@codemonster-ru/vueforge-theme
v2.0.1
Published
Shared theme engine, tokens, and preset runtime for the VueForge ecosystem.
Maintainers
Readme
VueForge Theme
A framework-agnostic token and preset engine for the VueForge ecosystem.
Coordinated release: @codemonster-ru/[email protected].
Requirements
- Node.js 18 or newer.
- No Vue peer dependency. Vue packages consume this engine internally.
Install
npm install @codemonster-ru/vueforge-themepnpm add @codemonster-ru/vueforge-themeyarn add @codemonster-ru/vueforge-themeQuick start
The package has one ESM entry and no CSS side effects:
import {
resolveThemeConfig,
themePresetToCssText,
themeTokensToCssVars,
vfBreakpoints,
} from '@codemonster-ru/vueforge-theme';
const variables = themeTokensToCssVars({
colorBackgroundCanvas: '#fff',
breakpoint2xl: '96rem',
});The engine intentionally does not ship an application default preset. Use the preset from
VueForge Core or provide a complete VfThemePreset before calling resolveThemeConfig.
themePresetToCssText is safe to use during SSR. applyThemeConfig writes to a Document, so
call it only in a browser or pass an explicit DOM document.
Package-local documentation
The public contract is available directly in src/index.ts, src/types.ts, and CHANGELOG.md. Ecosystem upgrade requirements are documented in the repository VueForge 2 migration guide.
