Skip to content

Ember: Framework overhaul to use vite#33048

Open
mogstad wants to merge 5 commits into
storybookjs:nextfrom
mogstad:push-wmnzvqnyqvln
Open

Ember: Framework overhaul to use vite#33048
mogstad wants to merge 5 commits into
storybookjs:nextfrom
mogstad:push-wmnzvqnyqvln

Conversation

@mogstad
Copy link
Copy Markdown

@mogstad mogstad commented Nov 14, 2025

What I did

Ember just released Ember 6.8 with Vite as its default build system as well as support for rendering components directly to DOM, as well as passing arguments as an object, which makes it perfect to use to render stories in Storybook. To my understanding the current Ember renderer isn't compatible with Storybook v10 and I've therefor completely replaced it.

The new integration uses Vite which makes it possible to integrate with Storybook v10. The new integration doesn't boot the app by default, the ergonomics of using an app should be explored further.

Supersedes #32790

Checklist for Contributors

Testing

The changes in this PR are covered in the following automated tests:

  • stories
  • unit tests
  • integration tests
  • end-to-end tests

Manual testing

  1. yarn task --task sandbox --start-from auto --template ember/default-ts
  2. Open Storybook in your browser
  3. Ensure all stores are working as expected

Documentation

  • Add or update documentation reflecting your changes
  • If you are deprecating/removing a feature, make sure to update
    MIGRATION.MD

Checklist for Maintainers

  • When this PR is ready for testing, make sure to add ci:normal, ci:merged or ci:daily GH label to it to run a specific set of sandboxes. The particular set of sandboxes can be found in code/lib/cli-storybook/src/sandbox-templates.ts

  • Make sure this PR contains one of the labels below:

    Available labels
    • bug: Internal changes that fixes incorrect behavior.
    • maintenance: User-facing maintenance tasks.
    • dependencies: Upgrading (sometimes downgrading) dependencies.
    • build: Internal-facing build tooling & test updates. Will not show up in release changelog.
    • cleanup: Minor cleanup style change. Will not show up in release changelog.
    • documentation: Documentation only changes. Will not show up in release changelog.
    • feature request: Introducing a new feature.
    • BREAKING CHANGE: Changes that break compatibility in some way with current major version.
    • other: Changes that don't fit in the above categories.

🦋 Canary release

This PR does not have a canary release associated. You can request a canary release of this pull request by mentioning the @storybookjs/core team here.

core team members can create a canary release here or locally with gh workflow run --repo storybookjs/storybook publish.yml --field pr=<PR_NUMBER>

Summary by CodeRabbit

  • New Features

    • Dynamic HTML source rendering for Ember docs; improved Glimmer source generation and a source decorator.
    • New client-facing APIs and TypeScript types for Ember stories (Meta/StoryFn/StoryObj) and portable stories support.
    • New example components and stories (Button, Header, Page) with interaction (play) tests.
  • Chores

    • Migrated framework tooling and templates from Webpack to Vite; updated build and package exports and dependencies.

✏️ Tip: You can customize this high-level summary in your review settings.

@mogstad mogstad marked this pull request as draft November 14, 2025 19:52
Copy link
Copy Markdown
Contributor

@gossi gossi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is huge!!!

It's the foundation for integrating Ember with Storybook@10 through vite. Bringing all build systems together surely was a not-funny endeavor, so @mogstad did the herculean effort here.

This enables Ember for Storybook 10 in any form better than any previous implementation... and this is only the MVP. The more interessting work can start now.

Here is a list of things I see, we can do now (in no particular order):

  • Typedoc integrations (args and slots in docs mode)
  • Stories in gjs/gts (when you want to test/embed your components in HTML)
  • Provide Decorators for Ember Devs (to support Embers DI system, or else components break 🙈)
    • Mock services
    • Set application (also globally, work for owner already done)
  • Support CSF Next format for Ember
  • Vitest integration

Basically, what Yann showed at Viteconf is now in reach for Ember: https://www.youtube.com/watch?v=YNQ_cJ6yy2Q

So, this PR unlocks the implementations I listed. We can do this in parallel now, thanks to the foundation of this PR.

PS. This started in september when I reached out to ask for help in integrating with Ember and took until today. Thanks a lot to @ndelangen and @JReinhold for providing their tremendeous support here, much appreciated.

But most credit goes to @mogstad 🥳 🎉 💯

Comment thread code/frameworks/ember/src/client/render.ts
@nx-cloud
Copy link
Copy Markdown

nx-cloud Bot commented Nov 17, 2025

View your CI Pipeline Execution ↗ for commit 2d599d2


☁️ Nx Cloud last updated this comment at 2025-12-24 10:39:29 UTC

@storybook-app-bot
Copy link
Copy Markdown

storybook-app-bot Bot commented Nov 17, 2025

Package Benchmarks

Commit: 8cd1b46, ran on 25 March 2026 at 09:03:26 UTC

The following packages have significant changes to their size or dependencies:

@storybook/ember

Before After Difference
Dependency count 189 15 🎉 -174 🎉
Self size 15 KB 39 KB 🚨 +23 KB 🚨
Dependency size 28.93 MB 27.42 MB 🎉 -1.51 MB 🎉
Bundle Size Analyzer Link Link

@mogstad mogstad force-pushed the push-wmnzvqnyqvln branch 4 times, most recently from b80aeb6 to 935ae45 Compare November 21, 2025 08:33
@mogstad mogstad marked this pull request as ready for review December 11, 2025 15:27
@coderabbitai

This comment was marked as spam.

coderabbitai[bot]

This comment was marked as spam.

coderabbitai[bot]

This comment was marked as spam.

@ndelangen
Copy link
Copy Markdown
Member

@mogstad @gossi Shall we schedule a meeting? Perhaps during one of the triage meetings in discord? to talk about this PR it's state and it's future?

I'm personally very excited about all this work being done, and looking forward to learning it's internals a bit and figuring out how to get this released.

@ndelangen ndelangen changed the title Rework Ember framework to use Vite Ember: Framework overhaul to use vite Dec 24, 2025
@github-actions github-actions Bot added the Stale label Jan 9, 2026
@jonniebigodes
Copy link
Copy Markdown
Contributor

@mogstad, can you take a look at #27186 and coordinate with @benedik to see if his work fits into this overhaul of the Ember framework?

@benedikt
Copy link
Copy Markdown

This PR is pretty much the "Long Term Solution" we described in #27186. We're happy to help with this one. Let us know how we can do so 😄

@github-actions github-actions Bot added the Stale label Feb 9, 2026
@valentinpalkovic
Copy link
Copy Markdown
Contributor

Closing due to inactivity. Please feel free to open a new PR if you want to continue the work. Thanks for your contributions so far!

@gossi
Copy link
Copy Markdown
Contributor

gossi commented Mar 10, 2026

We were already in contact with @ndelangen via Discord. I pinged him this week.

I carefully hit reopen here, as talks happen currently in Discord (let's say we took an extended christmas break).

@valentinpalkovic I hope reopening this is ok for you :)

@gossi gossi reopened this Mar 10, 2026
@github-actions github-actions Bot removed the Stale label Mar 11, 2026
@github-actions github-actions Bot added the Stale label Mar 22, 2026
@LucasHillDex
Copy link
Copy Markdown

@mogstad @gossi any help needed to push this over the finish line?

@github-actions github-actions Bot removed the Stale label Mar 25, 2026
@mogstad mogstad force-pushed the push-wmnzvqnyqvln branch from 2d599d2 to 18ed633 Compare March 25, 2026 08:36
@valentinpalkovic valentinpalkovic moved this to Empathy Queue (prioritized) in Core Team Projects Apr 7, 2026
@github-actions github-actions Bot added the Stale label Apr 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Empathy Queue (prioritized)

Development

Successfully merging this pull request may close these issues.

7 participants