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

[Bug]: module.less file reports an error when packaging (rsbuild build) #2928

Closed
JayMo666 opened this issue Jul 15, 2024 · 2 comments
Closed
Labels
🐞 bug Something isn't working

Comments

@JayMo666
Copy link

JayMo666 commented Jul 15, 2024

Version

module.less file reports an error when packaging (rsbuild build), @primary-color is a less variable in antd V4.

System:
    OS: macOS 14.5
    CPU: (8) arm64 Apple M1 Pro
    Memory: 123.38 MB / 16.00 GB
    Shell: 5.9 - /bin/zsh
  Browsers:
    Chrome: 126.0.6478.127
    Chrome Canary: 128.0.6596.0
    Safari: 17.5
  npmPackages:
    @rsbuild/core: 1.0.1-beta.1 => 1.0.1-beta.1 
    @rsbuild/plugin-less: 1.0.1-beta.1 => 1.0.1-beta.1 
    @rsbuild/plugin-react: 1.0.1-beta.1 => 1.0.1-beta.1 
    @rsbuild/plugin-svgr: 1.0.1-beta.1 => 1.0.1-beta.1

Details

image

Reproduce link

Reproduce Steps

pnpm run build

@JayMo666 JayMo666 added the 🐞 bug Something isn't working label Jul 15, 2024
@JayMo666
Copy link
Author

已通过配置rsbuild.config.js解决
pluginLess({
lessLoaderOptions: {
lessOptions: {
modifyVars: {
'primary-color': '#3f85fc',
}
}
})

@chenjiahan chenjiahan changed the title [Bug]: module.less文件在打包时(rsbuild build)报错,@primary-color是antd V4版本中的less 变量。 [Bug]: module.less file reports an error when packaging (rsbuild build) Jul 15, 2024
@chenjiahan
Copy link
Member

Get, seems to be unrelated to Rsbuild, I will close this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐞 bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants