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

Using multiple @use in SASS files results in duplicated styles #17250

Open
Mikilll94 opened this issue Jan 16, 2022 · 1 comment
Open

Using multiple @use in SASS files results in duplicated styles #17250

Mikilll94 opened this issue Jan 16, 2022 · 1 comment

Comments

@Mikilll94
Copy link

Describe the bug
When using multiple times the same @use rule is SASS files, Storybook outputs duplicated styles.

Screenshot 2022-01-16 at 14 06 06

As you can see example-style class is duplicated because rule @use '../sass-lib/lib' is used in multiple stories.

To Reproduce
https://github.com/Mikilll94/storybook-duplicated-styles

System

Environment Info:

  System:
    OS: macOS 11.6.1
    CPU: (16) x64 Intel(R) Core(TM) i9-9980HK CPU @ 2.40GHz
  Binaries:
    Node: 16.13.0 - /usr/local/bin/node
    Yarn: 3.1.1 - /usr/local/bin/yarn
    npm: 8.1.0 - /usr/local/bin/npm
  Browsers:
    Chrome: 97.0.4692.71
    Firefox: 96.0
    Safari: 15.2
  npmPackages:
    @storybook/addon-actions: ^6.5.0-alpha.17 => 6.5.0-alpha.17 
    @storybook/addon-docs: ^6.5.0-alpha.17 => 6.5.0-alpha.17 
    @storybook/addon-essentials: ^6.5.0-alpha.17 => 6.5.0-alpha.17 
    @storybook/addon-links: ^6.5.0-alpha.17 => 6.5.0-alpha.17 
    @storybook/html: ^6.5.0-alpha.17 => 6.5.0-alpha.17

Additional context
When I create a standard Webpack project without Storybook, multiple uses of @use rule does not output duplicated styles.

@maber1
Copy link

maber1 commented Mar 10, 2024

I have the same problem, did you manage to solve it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants