Skip to content

Commit e8feb11

Browse files
authored
Fixed issue for better bundles,chunks and workers name in devtools-extensions. (#22322)
1 parent f4ac680 commit e8feb11

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

packages/react-devtools-extensions/src/main.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -331,7 +331,9 @@ function createPanelIfReactLoaded() {
331331

332332
// TODO (Webpack 5) Hopefully we can remove this prop after the Webpack 5 migration.
333333
const hookNamesModuleLoaderFunction = () =>
334-
import('react-devtools-shared/src/hooks/parseHookNames');
334+
import(
335+
/* webpackChunkName: 'parseHookNames' */ 'react-devtools-shared/src/hooks/parseHookNames'
336+
);
335337

336338
root = createRoot(document.createElement('div'));
337339

packages/react-devtools-extensions/webpack.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,7 @@ module.exports = {
114114
loader: 'workerize-loader',
115115
options: {
116116
inline: true,
117+
name: '[name]',
117118
},
118119
},
119120
{

0 commit comments

Comments
 (0)