System Info
System:
OS: macOS 15.7.5
CPU: (12) arm64 Apple M2 Max
Memory: 98.22 MB / 32.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 24.14.0
npm: 11.9.0
pnpm: 11.8.0
bun: 1.3.13
Deno: 2.1.7
Browsers:
Chrome: 149.0.7827.115
Edge: 149.0.4022.80
Firefox: 131.0
Safari: 26.4
Details
如图配置了虚拟模块插件,并在 thisCompilation 里用 writeModule 更新虚拟模块代码,项目启动完成后,修改项目真实文件(如:App.tsx )时,更新的虚拟模块不会进入 loader,也无法热更新:
English (Google translate):
As shown in the image, a virtual module plugin is configured, and the virtual module code is updated using writeModule in thisCompilation. After the project starts, when modifying the actual project files (e.g., App.tsx), the updated virtual module will not enter the loader, and hot reloading is not possible.
Reproduce link
https://github.com/moonsky-all/demo-rsbuild
Reproduce Steps
如上
System Info
System:
OS: macOS 15.7.5
CPU: (12) arm64 Apple M2 Max
Memory: 98.22 MB / 32.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 24.14.0
npm: 11.9.0
pnpm: 11.8.0
bun: 1.3.13
Deno: 2.1.7
Browsers:
Chrome: 149.0.7827.115
Edge: 149.0.4022.80
Firefox: 131.0
Safari: 26.4
Details
如图配置了虚拟模块插件,并在 thisCompilation 里用 writeModule 更新虚拟模块代码,项目启动完成后,修改项目真实文件(如:App.tsx )时,更新的虚拟模块不会进入 loader,也无法热更新:
English (Google translate):
As shown in the image, a virtual module plugin is configured, and the virtual module code is updated using
writeModuleinthisCompilation. After the project starts, when modifying the actual project files (e.g.,App.tsx), the updated virtual module will not enter the loader, and hot reloading is not possible.Reproduce link
https://github.com/moonsky-all/demo-rsbuild
Reproduce Steps
如上