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

Lazy loaded Linaria components have wrong specificity when decorated with styled() #1415

Open
jalooc opened this issue Jun 30, 2024 · 0 comments
Labels
bug report 🦗 Issue is probably a bug, but it needs to be checked needs: complete repro 🖥️ Issue need to have complete repro provided

Comments

@jalooc
Copy link

jalooc commented Jun 30, 2024

Environment

  • Linaria version: 6.2.0
  • Linaria React version: 6.2.1
  • Bundler (+ version): Vite @5.2.13
  • Node.js version: v22.2.0
  • OS: MacOS

Description

When decorating Linaria components with styled(), the resulting class has proper specificity achieved by chaining classes: .classBaseComponent.classDecoratingComponent, but that does not work if the base component is lazy-loaded.

image image

Reproducible Demo

https://stackblitz.com/edit/stackblitz-starters-ldrzpa

@jalooc jalooc added bug report 🦗 Issue is probably a bug, but it needs to be checked needs: complete repro 🖥️ Issue need to have complete repro provided needs: triage 🏷 Issue needs to be checked and prioritized labels Jun 30, 2024
@github-actions github-actions bot removed the needs: triage 🏷 Issue needs to be checked and prioritized label Jun 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug report 🦗 Issue is probably a bug, but it needs to be checked needs: complete repro 🖥️ Issue need to have complete repro provided
Projects
None yet
Development

No branches or pull requests

1 participant