Skip to content

Conversation

@JReinhold
Copy link
Collaborator

@JReinhold JReinhold commented Jul 21, 2025

Updated addon-kit to only output ESM, in accordance with Storybook 10.

  • Removed the exportEntries bundle option, as it was ambiguous and unnecessary. It should be very rare that addons will have code that should both be importable by end-users in Node and manager/preview. So now all entry points must either be node, manager or preview types.
  • Upgraded all dependencies

Do not merge until Storybook 10 is released

Before merging:

  • Update docs/addons/addon-migration-guide.mdx to point to main instead of this branch
- Storybook 10 requires all addons to be built as ESM-only. This change simplifies the build process and reduces maintenance overhead. You'll need to make many changes to `tsup.config.ts`, so it can be easier to copy the reference file in the [`addon-kit` repository](https://github.com/storybookjs/addon-kit/blob/esm-only/tsup.config.ts).
+ Storybook 10 requires all addons to be built as ESM-only. This change simplifies the build process and reduces maintenance overhead. You'll need to make many changes to `tsup.config.ts`, so it can be easier to copy the reference file in the [`addon-kit` repository](https://github.com/storybookjs/addon-kit/blob/main/tsup.config.ts).

@JReinhold JReinhold requested a review from ndelangen July 21, 2025 14:19
@JReinhold JReinhold self-assigned this Jul 21, 2025
@JReinhold JReinhold added the enhancement New feature or request label Jul 21, 2025
@JReinhold JReinhold marked this pull request as ready for review July 21, 2025 14:19
@Sidnioulz
Copy link
Member

@JReinhold FYI the addon migration guide currently refers to this branch's tsup config file as addon authors start migrating ahead of release.

But once this is merged, I'll need to know so I can go and point that URL to main on the addon-migration-guide instead of esm-only.

@ndelangen ndelangen merged commit e443fd0 into main Oct 28, 2025
5 checks passed
@ndelangen ndelangen deleted the esm-only branch October 28, 2025 13:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants