@praxisjs/storybook
Changelog for @praxisjs/storybook — Storybook framework adapter for PraxisJS.
@praxisjs/storybook
0.3.3
Depends on the other @praxisjs/* packages through caret ranges (^2.3.0) instead of exact versions, so npm no longer installs a second copy of a package when two releases disagree, and upgrades no longer end in peer conflicts.
0.3.0
The published package no longer contains the package's tests (compiled tests in dist/__tests__, test sources in src/__tests__).
.storybook/preview.ts needs no setup. The preset now registers @praxisjs/storybook/preview through previewAnnotations. It provides renderToCanvas and a default render that mounts the meta's component with the story's args as props, so a story can be just { args: { … } }. Exporting renderToCanvas from your own preview.ts, as before, still works. See Setup.
Bug fixes:
- Changing a story's args (or an HMR update) mounted the story again without disposing the previous render, whose effects and listeners stayed alive. Every render of a canvas now disposes what the canvas held first, and
onUnmountruns. - All canvases shared one cleanup, so on a docs page a remount of one story could unmount another. Each canvas now tracks its own story.
renderToCanvasreturns a teardown, so Storybook disposes the story when it leaves the canvas.- The manager and preview entry paths were taken from a URL's
pathname, which keeps%20for spaces and a leading/before Windows drive letters. They are now real file paths.
The source panel reads story files asynchronously instead of blocking Vite's transform, and *.story.* files now get the source panel too, matching the files the indexer picks up. The indexer no longer matches files such as history.ts whose name merely ends in story.
0.2.4
Removed the @storybook/core dependency and peer dependency — it never published a Storybook 9/10 release, so it dragged in a stale @storybook/[email protected] that conflicted with [email protected] and pinned esbuild below what [email protected] requires. Internal imports moved from @storybook/core/csf and @storybook/core/types to storybook/internal/csf and storybook/internal/types — no change to Meta, StoryObj, or any other public export.
0.2.1
Added the missing sourceUrl and expanded fields to StorybookRefs, matching the options documented for Storybook Composition refs.
0.2.0
Added refs support to StorybookConfig for Storybook Composition — reference other published Storybooks from your sidebar. Exports a new StorybookRefs type.
0.1.1
Updated dependencies — @praxisjs/[email protected].
0.1.0
Initial release — Storybook framework adapter for PraxisJS. Mounts components via @praxisjs/runtime, integrates @praxisjs/vite-plugin automatically, and exports Meta, StoryObj, and StorybookConfig types.