Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docs: Remove STORYBOOK_REACT_CLASSES and global/globals.ts #19300

Merged
merged 4 commits into from
Oct 3, 2022

Conversation

IanVS
Copy link
Member

@IanVS IanVS commented Sep 30, 2022

Issue:

What I did

I could be wrong, but it seems like STORYBOOK_REACT_CLASSES isn't actually used anywhere. Though, I found where it was added: #557, and it didn't really seem used there either, so maybe I'm missing something. But, it's adding a bit of extra complexity since this is injected into config via

return [...config, require.resolve('@storybook/core-client/dist/esm/globals/globals'), ...base];
. The vite builder's docgen plugin does not use this global, and things seem to be working fine.

In the name of simplifying things, I figured I'd try removing it, and see what happens. But maybe users are relying on this, somehow?

How to test

  • Is this testable with Jest or Chromatic screenshots?
  • Does this need a new example in the kitchen sink apps?
  • Does this need an update to the documentation?

Maybe an update to the docs?

@shilman
Copy link
Member

shilman commented Sep 30, 2022

This feels good to me. It only existed for back compat in the early days of docs. If we make this change, we'll need to add a note to MIGRATION.md

@IanVS IanVS requested a review from shilman September 30, 2022 12:39
@ndelangen ndelangen merged commit a14ca00 into next Oct 3, 2022
@ndelangen ndelangen deleted the remove-react-classes-global branch October 3, 2022 14:46
@shilman shilman added maintenance User-facing maintenance tasks build Internal-facing build tooling & test updates and removed other maintenance User-facing maintenance tasks labels Oct 4, 2022
@github-actions
Copy link
Contributor

github-actions bot commented Oct 4, 2022

Fails
🚫

PR is not labeled with one of: ["cleanup","BREAKING CHANGE","feature request","bug","documentation","maintenance","dependencies","other"]

Generated by 🚫 dangerJS against bba5c8c

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build Internal-facing build tooling & test updates
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants