You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The builtin:lightningcss-loader will not take any effect, because css-loader will read the AST meta from postcss-loader, and drop the transformation result of builtin:lightningcss-loader.
This is probably caused by the logic of the Rust loader implementations. On rust side, we does not expose an API to override the values at once (content, sourceMap, additionalData). In this case, it caused the additionalData being accidentally passed onto the next loader.
System Info
Rspack 1.0.3
Details
In webpack, the
meta
param of loader can only be passed to the next loader, and the bulitin loaders in Rspack should follow the same behavior.Example
For example, the
css-loader
andpostcss-loader
usesmeta.ast
to resue PostCSS AST, see:When using Rspack's
builtin:lightningcss-loader
like this:postcss-loader ---passing AST meta---> builtin:lightningcss-loader ---passing AST meta---> css-loader
The
builtin:lightningcss-loader
will not take any effect, becausecss-loader
will read the AST meta frompostcss-loader
, and drop the transformation result ofbuiltin:lightningcss-loader
.Reproduce link
web-infra-dev/rsbuild#3247
Reproduce Steps
See web-infra-dev/rsbuild#3247 for more details.
The text was updated successfully, but these errors were encountered: