We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
&
System: OS: Linux 6.1 Debian GNU/Linux 11 (bullseye) 11 (bullseye) CPU: (32) x64 13th Gen Intel(R) Core(TM) i9-13900K Memory: 44.37 GB / 62.38 GB Container: Yes Shell: 5.8 - /usr/bin/zsh Browsers: Chrome: 131.0.6778.204 npmPackages: @rsbuild/core: ^1.1.8 => 1.1.14 @rsbuild/plugin-less: ^1.1.0 => 1.1.0 @rsbuild/plugin-react: ^1.0.7 => 1.1.0
This is the original code of less.
.test { background-color: rebeccapurple; } :global(.hello) { background-color: aqua; &-world { background-color: brown; } }
When I used the & operator, the built output did not include the class modified by &. The output is:
.test-vRkBOC{background-color:#639}.hello{background-color:#0ff}
https://codesandbox.io/p/github/gz65555/rsbuild-less-bug-feedback/main?import=true
pnpm i & pnpm build
You can see there is no .hello-world class here
.hello-world
The text was updated successfully, but these errors were encountered:
I think it's a problem cause by lightingcss, which is used by rsbuild.
If I don't use the lightingcss-loader, the result is ok.
Sorry, something went wrong.
@GiveMe-A-Name Can you take a look at this lightningcss related issue?
The css is not validate css by transform by less-loader, So lightningcss can't transform the css code correctly, lightningcss playground
After less-loader, the css will become:
.test { background-color: rebeccapurple; } :global(.hello) { background-color: aqua; } /* invalidate */ :global(.hello)-world { background-color: brown; }
I think is not a bug in lightningcss, but recover error css can be lightningcss feature.
GiveMe-A-Name
No branches or pull requests
Version
Details
This is the original code of less.
When I used the
&
operator, the built output did not include the class modified by&
. The output is:Reproduce link
https://codesandbox.io/p/github/gz65555/rsbuild-less-bug-feedback/main?import=true
Reproduce Steps
pnpm i & pnpm build
You can see there is no
.hello-world
class hereThe text was updated successfully, but these errors were encountered: