Skip to content

Releases

0.3.0

Choose a tag to compare

@greeeg greeeg released this 23 Nov 07:57
4168e92

Highlights

Recontent 0.3.0 expands from design tokens into a full design system toolchain for humans and coding agents: React component introspection from TypeScript & JSDoc, recontent inspect for querying tokens, components, and types (including published npm snapshots), component-aware recontent diff, a revamped docs() plugin, new contrast(), designMD(), and inspect() plugins, and build --check for CI.

Features

  • Component introspection: The introspection config option reads React component props, defaults, types, and JSDoc (requires importPath for import statements), with on-disk caching (bypass with --no-cache).
  • recontent inspect: Browse tokens, components, and types as markdown or JSON, inspect an installed design system's published snapshot with --from, and search across tokens, components, and types by name, description, usage notes, or value with recontent inspect search <query...>.
  • Component & prop diffs: recontent diff now compares components and prop types in addition to tokens.
  • CI drift check: recontent build --check fails when generated files are missing or out of date.
  • New plugins:
    • contrast() fails the build when color pairs drop below a WCAG 2.x contrast ratio in base tokens or any theme.
    • designMD() writes DESIGN.md for coding agents.
    • inspect() emits the snapshot that recontent inspect --from reads.
  • Revamped docs() plugin: Now documents components alongside tokens, supporting @usage, @example, @link, @category, and @stories JSDoc tags.
  • Plugin helpers & diagnostics: Added resolveValue(ctx, entry, theme?) and aliasChain(ctx, entry, theme?) in recontent/plugins. Plugin diagnostics and errors now name the plugin and token that triggered them.

Breaking changes

  • Renamed recontent init --from <path> to recontent init --dtcg <path>.
  • Removed PluginContext.mode (no built-in plugin read it).
  • Removed CSS reset emission from stylex() and vanillaExtract(). Both plugins drop the fontFamily and placeholderColor options and no longer emit reset.gen.css or reset.gen.css.ts. Delete the generated reset files and their imports.
  • Theme names must now work across every output (letters, digits, underscores, and hyphens, without starting with a digit or hyphen). defineConfig() throws otherwise.
  • Emitting two files to the same path now fails the build, even from the same plugin (for example, two css() instances sharing an outDir or a dtcg() theme named tokens).

Bug fixes

  • recontent diff no longer loads base revision tokens through the working tree's tsconfig paths aliases, which previously hid or misreported changes.
  • A theme replacing a scale with tokens built from other tokens no longer drops the override.
  • recontent build --watch now reloads the config file after edits instead of reusing the initial config.
  • recontent init --force now succeeds when the config file already has identical content, and recontent init -c accepts paths outside --cwd.

Full Changelog: 0.2.0...0.3.0

0.2.0

Choose a tag to compare

@greeeg greeeg released this 23 Oct 16:01
5989cd7

Highlights

Initial public release of Recontent — a typed design token toolchain that stores design decisions in layered TypeScript configs, supports multi-theme overrides, and generates outputs for your stack via plugins.

Features

  • Typed token authoring: Define reference, system, and component token layers (defineReferenceTokens, defineSystemTokens, defineComponentTokens) with primitives, scales, color scale generation (tokens.generateColorScale, tokens.colorScale), composites, and type-checked aliases.
  • Themes: Override token values for dark mode, density, or brand variants with defineTheme() without changing component code.
  • CLI (init, build, diff):
    • recontent init scaffolds recontent.config.ts from built-in presets (neutral, material) or imports existing DTCG token files via --from <path>.
    • recontent build runs configured plugins and supports --watch for rebuilding on save.
    • recontent diff compares tokens against a previous git revision with --fail-on-breaking and configurable output formats.
  • Built-in plugins & plugin API: Ships with css(), tailwind(), stylex(), vanillaExtract(), typescript(), typescriptNative(), dtcg(), and docs() in recontent/plugins, plus a plugin API for custom outputs.

Full Changelog: https://github.com/recontentapp/recontent/commits/0.2.0