In the DOMManipulation project used throughout this chapter, webpack.config.js specifies a development profile through the mode: "development" setting, while the library bundle is built with a production profile since webpack.config.vendor.js specifies no mode setting. As a consequence, just the library bundle is minimized, while all other chunks and bundles are not minimized. Information about the profile may be passed either through WebPack middleware or as a WebPack parameter. In turn, the WebPack command may be invoked with the desired parameter when the Visual Studio project is published by hooking the publish event within the .csproj Visual Studio project file.
Let's use the DOMMAnipulation project we've been using. As a first step, let's modify webpack.config.js. Find the following code:
module.exports ...