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

Storybook: Isolate stylesheets between packages #49057

Closed
mirka opened this issue Mar 14, 2023 · 0 comments · Fixed by #49099
Closed

Storybook: Isolate stylesheets between packages #49057

mirka opened this issue Mar 14, 2023 · 0 comments · Fixed by #49099
Assignees
Labels
Developer Experience Ideas about improving block and theme developer experience Storybook Storybook and its stories for components [Type] Enhancement A suggestion for improvement.

Comments

@mirka
Copy link
Member

mirka commented Mar 14, 2023

What problem does this address?

As more packages start to use Storybook (e.g. #49031), we have a higher risk of the main built stylesheet of each package affecting other package stories.

Ideally we would not have unscoped/overscoped CSS in the package stylesheets, but a quick look into some of them do definitely uncover selectors that break package boundaries.

What is your proposed solution?

Add some kind of system to only load package stylesheets that are declared as dependencies of a given story group.

@mirka mirka added Storybook Storybook and its stories for components Developer Experience Ideas about improving block and theme developer experience labels Mar 14, 2023
@mirka mirka self-assigned this Mar 14, 2023
@Thelmachido Thelmachido added the [Type] Enhancement A suggestion for improvement. label Mar 15, 2023
@github-actions github-actions bot added the [Status] In Progress Tracking issues with work in progress label Mar 15, 2023
@priethor priethor removed the [Status] In Progress Tracking issues with work in progress label May 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Developer Experience Ideas about improving block and theme developer experience Storybook Storybook and its stories for components [Type] Enhancement A suggestion for improvement.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants