Skip to content

v2.0.1 — Plugin options, provider options & frontend fixes

Choose a tag to compare

@toozuuu toozuuu released this 04 Mar 03:18
· 12 commits to main since this release

TokiForge v2.0.1

Patch release with new plugin and provider options, frontend fixes, and docs updates.

Fixes

  • Playground: ThemeRuntime lifecycle (state + effect init/destroy); no re-creation every render
  • React: ThemeContext single init with proper cleanup; Remix/Next provider effect deps and runtime.destroy() on unmount
  • SSR: Removed unused cookieMaxAge destructure in generateSSRHead (build fix)

New options

Theme providers (React, Vue, Next, Remix)

  • storageKey — LocalStorage key for theme persistence (default: tokiforge-theme)
  • persist — Read/write theme from storage (default: true)
  • onThemeChange — Callback when theme changes (e.g. analytics)
  • React: suppressHydrationWarning for root/body

Tailwind plugin

  • baseSelector, strict, includeUtilities, excludePaths, tokens, customUtilityPrefix, debug
  • themeMappings: added boxShadow, lineHeight, animation

SSR

  • cookieName and cookieMaxAge in generateSSRHead options

Core

  • Generic Plugin<TOptions> and optional optionsSchema on Plugin interface

Other

  • Playground: error boundary, lazy tabs, virtualized token list, a11y (ARIA/keyboard, button types, labels), Prettier
  • Reduced any / unknown in catch blocks; error boundaries in examples

Upgrade: npm install @tokiforge/core@^2.0.1 @tokiforge/react@^2.0.1 (or your adapter). See CHANGELOG for full details.