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

fix: mixin bug with experimentalSelectorInference #2909

Merged
merged 1 commit into from
Oct 1, 2023

Conversation

idoros
Copy link
Collaborator

@idoros idoros commented Sep 28, 2023

This PR fixes an edge case regression that causes a build error. The case involves a combination of mixin as the selector of @st-scope with the experimentalSelectorInference=true mode.

The difference is that when experimentalSelectorInference is on, the transformer doesn't flat @st-scope before running, and the alternative @st-scope transformation flow doesn't pass the inferred selector mixin value to transform the mixin fragment.

The fix is simply passing along the inferred value to the @st-scope transformation process, so it can work in the same way.

This is a quick/dirty fix, but I would like to refactor the entire process to handle all the context and inference values in a cleaner way.

this fix will also be backported to version 5.

@idoros idoros added bug Unexpected behavior or exception core Processing and transforming logic mixin CSS and JS Mixins labels Sep 28, 2023
@idoros idoros self-assigned this Sep 28, 2023
@idoros idoros requested a review from barak007 September 28, 2023 06:55
@idoros idoros merged commit 0a5facd into master Oct 1, 2023
12 checks passed
@idoros idoros deleted the ido/fix-mixin-st-scope-with-exp-selector-inference branch October 1, 2023 10:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Unexpected behavior or exception core Processing and transforming logic mixin CSS and JS Mixins
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants