Migration from CRA - Uncaught ReferenceError: _Lock__WEBPACK_IMPORTED_MODULE_1__ is not defined #1633
-
Hello! There isn't any warnings or errors in console for this is my rsbuild.config.ts export default defineConfig({
plugins: [pluginReact(), pluginSvgr()],
html: {
template: "./public/index.html",
},
server: {
port: 3000,
},
source: {
define: publicVars,
},
performance: {
chunkSplit: {
strategy: "split-by-module",
},
},
}); maybe someone know that I did wrong? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
it might be a treeshaking bug. pls try out the new treeshaking implementation with // rsbuild.config.ts
{
tools: {
rspack: {
experiments: {
rspackFuture: { newTreeshaking: true },
},
},
},
} or the workaround: import {FocusLockUI} from "react-focus-lock";
console.log(FocusLockUI); reference: https://discord.com/channels/977448667919286283/1209798834767667230 |
Beta Was this translation helpful? Give feedback.
it might be a treeshaking bug.
pls try out the new treeshaking implementation with
or the workaround:
reference: https://discord.com/channels/977448667919286283/1209798834767667230