diff --git a/src/content/configuration/resolve.mdx b/src/content/configuration/resolve.mdx index 06bcb3517fa0..6b15ecd23bc7 100644 --- a/src/content/configuration/resolve.mdx +++ b/src/content/configuration/resolve.mdx @@ -339,7 +339,7 @@ module.exports = { }; ``` -Alternatively, to prioritize the deault conditions first, then add your custom conditions: +Alternatively, to prioritize the default conditions first, then add your custom conditions: **webpack.config.js** diff --git a/src/content/guides/lazy-loading.mdx b/src/content/guides/lazy-loading.mdx index acd98dfb7879..80c1efeeb2cf 100644 --- a/src/content/guides/lazy-loading.mdx +++ b/src/content/guides/lazy-loading.mdx @@ -104,6 +104,6 @@ index.bundle.js 548 kB 1 [emitted] [big] index Many frameworks and libraries have their own recommendations on how this should be accomplished within their methodologies. Here are a few examples: -- React: [Code Splitting and Lazy Loading](https://reactjs.org/docs/code-splitting.html) +- React: [Code Splitting and Lazy Loading](https://react.dev/learn/build-a-react-app-from-scratch#code-splitting) - Vue: [Dynamic Imports in Vue.js for better performance](https://vuedose.tips/tips/dynamic-imports-in-vue-js-for-better-performance/) - Angular: [Lazy Loading route configuration](https://angular.io/guide/router#milestone-6-asynchronous-routing) and [AngularJS + webpack = lazyLoad](https://medium.com/@var_bin/angularjs-webpack-lazyload-bb7977f390dd) diff --git a/src/content/migrate/5.mdx b/src/content/migrate/5.mdx index 77a44fe80ebb..b4801396d844 100644 --- a/src/content/migrate/5.mdx +++ b/src/content/migrate/5.mdx @@ -13,6 +13,7 @@ contributors: - getsnoopy - yevhen-logosha - akash-kumar-dev + - EvanSanderson --- This guide aims to help you migrating to webpack 5 when using webpack directly. If you are using a higher level tool to run webpack, please refer to the tool for migration instructions. @@ -292,6 +293,10 @@ Repeat the following steps until you solved at least level 3 or 4: - 404 errors pointing to URLs containing `auto` - Not all ecosystem tooling is ready for the new default automatic `publicPath` via `output.publicPath: "auto"` - Use a static `output.publicPath: ""` instead. + - Cannot read properties of undefined (reading 'call') + - If you see this error during runtime, it may be related to the [ModuleConcatenationPlugin](https://webpack.js.org/plugins/module-concatenation-plugin/). Check if you are using the plugin, and if you've included it in the `plugins` sections of a config, and that config is also set to `production` mode, remove the plugin (ie `new webpack.optimize.ModuleConcatenationPlugin()`) from your plugins list. In webpack 5, the plugin is enabled by default in production mode, and it may get included twice. + - In general, disabling each plugin and testing the build is a good way to triage where the issue might be coming from. + - See: [this issue](https://github.com/webpack/webpack/discussions/15369#discussioncomment-13420496) for more details. - Level 6: **Deprecation Warnings**.