TypeError [ERR_UNKNOWN_FILE_EXTENSION]: Unknown file extension ".ts" for ./webpack.config.ts
You might encounter this error in the case of using native ESM in TypeScript (i.e. type: "module" in package.json).
webpack-cli supports configuration in both CommonJS and ESM format, at first it tries to load a configuration using require(), once it fails with an error code of 'ERR_REQUIRE_ESM' (a special code for this case) it would try to load the configuration using import().
-However, the import() method won't work with ts-node without loader hooks enabled (described at TypeStrong/ts-node#1007).
To fix the error above use the following command:
NODE_OPTIONS="--loader ts-node/esm" npx webpack --entry ./src/index.js --mode production
The Compilation object has many methods and hooks available. On this page, we will list the available methods and properties.
compilation object methods
getStats
function
Returns Stats object for the current compilation.
addModule
function (module, callback)
Adds a module to the current compilation.
Parameters:
module - module to be added
callback - a callback after the module has been added
getModule
function (module)
Fetches a module from a compilation by its identifier.
Parameters:
module - module to be fetched. The identifier is extracted from the module by the compilation using module.identifier() method.
findModule
function (module)
Attempts to search for a module by its identifier.
Parameters:
module - module to be searched for. The identifier is extracted from the module by the compilation using module.identifier() method.
buildModule
function (module, optional, origin, dependencies)
Builds the given module.
Parameters:
module - the module to be built.
optional - optional flag.
origin - origin module from which this module build was requested.
dependencies - optional dependencies of the module to be built.
processModuleDependencies
function (module, callback)
Process the given module dependencies.
Parameters:
module - module to be processed for the dependencies.
callback - function to be invoked when dependencies of the module had been processed.
addEntry
function (context, entry, name, callback)
Adds an entry to the compilation.
Parameters:
context - context path for entry.
entry - entry dependency.
name - the name of entry.
callback - function to be invoked when addEntry finishes.
rebuildModule
function (module, thisCallback)
Triggers a re-build of the module.
Parameters:
module - module to be rebuilt.
thisCallback - function to be invoked when the module finishes rebuilding.
finish
function (callback)
Finishes compilation and invokes the given callback.
Parameters:
callback - function to be invoked when the compilation has been finished.
seal
function (callback)
Seals the compilation.
Parameters:
callback - function to be invoked when the compilation has been sealed.
unseal
function
Unseals the compilation.
Parameters:
callback - function to be invoked when the compilation has been unsealed.
reportDependencyErrorsAndWarnings
function (module, blocks)
Adds errors and warnings of the given module to the compilation errors and warnings.
Parameters:
module - the module whose errors and warnings are to be reported.
blocks - a set of dependency blocks to report from.
addChunkInGroup
function (groupOptions, module, loc, request)
Adds module to an existing chunk group or creates a new one. Returns a chunkGroup.
Parameters:
groupOptions - options for the chunk group.
module - a module that references the chunk group.
loc - the location from which the chunk group is referenced (inside of the module).
request - the request from which the chunk group is referenced.
addChunk
function (name)
Creates and adds a new chunk to the compilation.chunks. Returns that chunk.
Parameters:
name - the name of the chunk.
assignDepth
function (module)
Assigns depth to the given module and its dependency blocks recursively.
Parameters:
module - the module to assign depth to.
getDependencyReference
function (module, dependency)
Returns the reference to the dependency from a given module.
Parameters:
module - the module at question.
dependency - the dependency to get reference to.
processDependenciesBlocksForChunkGroups
function (inputChunkGroups)
Creates the Chunk graph from the Module graph. The process is done in two phases. Phase one: traverse the module graph and build a basic chunks graph in chunkDependencies. Phase two: traverse every possible way through the basic chunk graph and track the available modules. While traversing, processDependenciesBlocksForChunkGroups connects chunks with each other and Blocks with Chunks. It stops traversing when all modules for a chunk are already available and it doesn't connect unneeded chunks.
Parameters:
inputChunkGroups - chunk groups that are processed.
removeReasonsOfDependencyBlock
function (module, block)
Removes relation of the module to the dependency block.
Parameters:
module - a module relationship to be removed.
block - dependency block.
patchChunksAfterReasonRemoval
function (module, chunk)
Patches ties of module and chunk after removing dependency reasons. Called automatically by removeReasonsOfDependencyBlock.
Parameters:
module - a module to patch tie.
chunk - a chunk to patch tie.
removeChunkFromDependencies
function (block, chunk)
Removes given chunk from a dependencies block module and chunks after removing dependency reasons. Called automatically by removeReasonsOfDependencyBlock.
Parameters:
block - block tie for Chunk.
chunk - a chunk to remove from dependencies.
sortItemsWithChunkIds
function
summarizeDependencies
function
createHash
function
createModuleAssets
function
createChunkAssets
function
getPath
function (filename, data)
Returns the interpolated path.
Parameters:
filename - used to get asset path with hash.
data - data object.
getPathWithInfo
function (filename, data)
Returns interpolated path and asset information.
Parameters:
filename - used to get asset path with hash.
data - data object.
createChildCompiler
function (name, outputOptions, plugins)
Allows running another instance of webpack inside of webpack. However, as a child with different settings and configurations applied. It copies all hooks and plugins from the parent (or top-level compiler) and creates a child Compiler instance. Returns the created Compiler.
Parameters:
name - name for the child Compiler.
outputOptions - output options object.
plugins - webpack plugins that will be applied.
checkConstraints
function
emitAsset
function (file, source, assetInfo = {})
Parameters:
file - file name of the asset
source - the source of the asset
assetInfo - additional asset information
updateAsset
function (file, newSourceOrFunction, assetInfoUpdateOrFunction)
Parameters:
file - file name of the asset
newSourceOrFunction - new asset source or function converting old to new
assetInfoUpdateOrFunction - new asset info or function converting old to new
deleteAsset
function (file)
Parameters:
file - file name of the asset
getAssets
function
Returns array of all assets under the current compilation.
The Compilation object has many methods and hooks available. On this page, we will list the available methods and properties.
compilation object methods
getStats
function
Returns Stats object for the current compilation.
addModule
function (module, callback)
Adds a module to the current compilation.
Parameters:
module - module to be added
callback - a callback after the module has been added
getModule
function (module)
Fetches a module from a compilation by its identifier.
Parameters:
module - module to be fetched. The identifier is extracted from the module by the compilation using module.identifier() method.
findModule
function (module)
Attempts to search for a module by its identifier.
Parameters:
module - module to be searched for. The identifier is extracted from the module by the compilation using module.identifier() method.
buildModule
function (module, optional, origin, dependencies)
Builds the given module.
Parameters:
module - the module to be built.
optional - optional flag.
origin - origin module from which this module build was requested.
dependencies - optional dependencies of the module to be built.
processModuleDependencies
function (module, callback)
Process the given module dependencies.
Parameters:
module - module to be processed for the dependencies.
callback - function to be invoked when dependencies of the module had been processed.
addEntry
function (context, entry, name, callback)
Adds an entry to the compilation.
Parameters:
context - context path for entry.
entry - entry dependency.
name - the name of entry.
callback - function to be invoked when addEntry finishes.
rebuildModule
function (module, thisCallback)
Triggers a re-build of the module.
Parameters:
module - module to be rebuilt.
thisCallback - function to be invoked when the module finishes rebuilding.
finish
function (callback)
Finishes compilation and invokes the given callback.
Parameters:
callback - function to be invoked when the compilation has been finished.
seal
function (callback)
Seals the compilation.
Parameters:
callback - function to be invoked when the compilation has been sealed.
unseal
function
Unseals the compilation.
Parameters:
callback - function to be invoked when the compilation has been unsealed.
reportDependencyErrorsAndWarnings
function (module, blocks)
Adds errors and warnings of the given module to the compilation errors and warnings.
Parameters:
module - the module whose errors and warnings are to be reported.
blocks - a set of dependency blocks to report from.
addChunkInGroup
function (groupOptions, module, loc, request)
Adds module to an existing chunk group or creates a new one. Returns a chunkGroup.
Parameters:
groupOptions - options for the chunk group.
module - a module that references the chunk group.
loc - the location from which the chunk group is referenced (inside of the module).
request - the request from which the chunk group is referenced.
addChunk
function (name)
Creates and adds a new chunk to the compilation.chunks. Returns that chunk.
Parameters:
name - the name of the chunk.
assignDepth
function (module)
Assigns depth to the given module and its dependency blocks recursively.
Parameters:
module - the module to assign depth to.
getDependencyReference
function (module, dependency)
Returns the reference to the dependency from a given module.
Parameters:
module - the module at question.
dependency - the dependency to get reference to.
processDependenciesBlocksForChunkGroups
function (inputChunkGroups)
Creates the Chunk graph from the Module graph. The process is done in two phases. Phase one: traverse the module graph and build a basic chunks graph in chunkDependencies. Phase two: traverse every possible way through the basic chunk graph and track the available modules. While traversing, processDependenciesBlocksForChunkGroups connects chunks with each other and Blocks with Chunks. It stops traversing when all modules for a chunk are already available and it doesn't connect unneeded chunks.
Parameters:
inputChunkGroups - chunk groups that are processed.
removeReasonsOfDependencyBlock
function (module, block)
Removes relation of the module to the dependency block.
Parameters:
module - a module relationship to be removed.
block - dependency block.
patchChunksAfterReasonRemoval
function (module, chunk)
Patches ties of module and chunk after removing dependency reasons. Called automatically by removeReasonsOfDependencyBlock.
Parameters:
module - a module to patch tie.
chunk - a chunk to patch tie.
removeChunkFromDependencies
function (block, chunk)
Removes given chunk from a dependencies block module and chunks after removing dependency reasons. Called automatically by removeReasonsOfDependencyBlock.
Parameters:
block - block tie for Chunk.
chunk - a chunk to remove from dependencies.
sortItemsWithChunkIds
function
summarizeDependencies
function
createHash
function
createModuleAssets
function
createChunkAssets
function
getPath
function (filename, data)
Returns the interpolated path.
Parameters:
filename - used to get asset path with hash.
data - data object.
getPathWithInfo
function (filename, data)
Returns interpolated path and asset information.
Parameters:
filename - used to get asset path with hash.
data - data object.
createChildCompiler
function (name, outputOptions, plugins)
Allows running another instance of webpack inside of webpack. However, as a child with different settings and configurations applied. It copies all hooks and plugins from the parent (or top-level compiler) and creates a child Compiler instance. Returns the created Compiler.
Parameters:
name - name for the child Compiler.
outputOptions - output options object.
plugins - webpack plugins that will be applied.
checkConstraints
function
emitAsset
function (file, source, assetInfo = {})
Parameters:
file - file name of the asset
source - the source of the asset
assetInfo - additional asset information
updateAsset
function (file, newSourceOrFunction, assetInfoUpdateOrFunction)
Parameters:
file - file name of the asset
newSourceOrFunction - new asset source or function converting old to new
assetInfoUpdateOrFunction - new asset info or function converting old to new
deleteAsset
function (file)
Parameters:
file - file name of the asset
getAssets
function
Returns array of all assets under the current compilation.
The ContextModuleFactory module is used by the Compiler to generate dependencies from webpack specific require.context API. It resolves the requested directory, generates requests for each file and filters against passed regExp. Matching dependencies then passes through NormalModuleFactory.
The ContextModuleFactory class extends Tapable and provides the following
lifecycle hooks. They can be tapped the same way as compiler hooks:
As with the compiler, tapAsync and tapPromise may also be available
-depending on the type of hook.
beforeResolve
AsyncSeriesWaterfallHook
Called before resolving the requested directory. The request can be ignored by returning false.
Callback Parameters: data
afterResolve
AsyncSeriesWaterfallHook
Called after the requested directory resolved.
Callback Parameters: data
contextModuleFiles
SyncWaterfallHook
Called after directory contents are read. On recursive mode, calls for each sub-directory as well. Callback parameter is an array of all file and folder names in each directory.
Callback Parameters: fileNames
alternativeRequests
AsyncSeriesWaterfallHook
Called for each file after the request is created but before filtering against regExp.
The NormalModuleFactory module is used by the Compiler to generate modules. Starting with entry points, it resolves each request, parses the content to find further requests, and keeps crawling through files by resolving all and parsing any new files. At last stage, each dependency becomes a Module instance.
The NormalModuleFactory class extends Tapable and provides the following
lifecycle hooks. They can be tapped the same way as compiler hooks:
As with the compiler, tapAsync and tapPromise may also be available
-depending on the type of hook.
beforeResolve
AsyncSeriesBailHook
Called when a new dependency request is encountered. A dependency can be ignored by returning false. Otherwise, it should return undefined to proceed.
Callback Parameters: resolveData
factorize
AsyncSeriesBailHook
Called before initiating resolve. It should return undefined to proceed.
Callback Parameters: resolveData
resolve
AsyncSeriesBailHook
Called before the request is resolved. A dependency can be ignored by returning false. Returning a Module instance would finalize the process. Otherwise, it should return undefined to proceed.
Callback Parameters: resolveData
resolveForScheme
AsyncSeriesBailHook
Called before a request with scheme (URI) is resolved.
Callback Parameters: resolveData
afterResolve
AsyncSeriesBailHook
Called after the request is resolved.
Callback Parameters: resolveData
createModule
AsyncSeriesBailHook
Called before a NormalModule instance is created.
Callback Parameters: createDataresolveData
createModuleClass
HookMap<SyncBailHook>
5.81.0+
A hook that allows you to override the NormalModule class when creating modules. This hook is called after the createModule hook and before the module hook.
Hook Parameters: identifier
Callback Parameters: createDataresolveData
module
SyncWaterfallHook
Called after a NormalModule instance is created.
Callback Parameters: modulecreateDataresolveData
createParser
HookMap<SyncBailHook>
Called before a Parser instance is created. parserOptions is options in module.parser for the corresponding identifier or an empty object.
Hook Parameters: identifier
Callback Parameters: parserOptions
parser
HookMap<SyncHook>
Fired after a Parser instance is created.
Hook Parameters: identifier
Callback Parameters: parserparserOptions
Possible default identifiers:
javascript/auto
javascript/dynamic
javascript/esm
json
webassembly/sync
webassembly/async
asset
createGenerator
HookMap<SyncBailHook>
Called before a Generator instance is created. generatorOptions is options in module.parser for the corresponding identifier or an empty object.
A curated list of awesome webpack resources, libraries, tools and applications. It is inspired by the awesome list. Feel free to improve this list by contributing.
Generate package.json Plugin - Limit dependencies in a deployment package.json to only those that are actually being used by your bundle. -- Maintainer: Paul Myburgh
build-hash-webpack-plugin For each build, Webpack generates an in-memory hash allowing to know if two build outputs are the same or not. This plugin writes the described build hash in a separate json file. -- Maintainer: Réda Housni Alaoui
webpack-hook-plugin - run any shell commands before or after webpack builds -- Maintainer: David Kwon
Dynamic Vendor Webpack Plugin - Gives you a way to import vendors with dynamic variable and specific code splitting. -- MaintainerLilian Saget-Lethias
Define Variable Webpack Plugin - Enhancement of DefinePlugin to store defined things in actual variables. -- MaintainerLilian Saget-Lethias
webpack-typescript-directory-compile-plugin Configure an source directory of typescript files and an output directory for JavaScript files. Each typescript file in the source directory and any newly added files will be compiled to individual JavaScript files. -- Maintainer: Stephen Sigwart
CycloneDX Webpack Plugin: Create CycloneDX Software Bill of Materials (SBOM) from webpack bundles at compile time. -- Maintainer: OWASP CycloneDX Team
Transpile Webpack Plugin: Transpiles input files into output files individually without bundling together. -- Maintainer: Chungen Li
Webpack Tools
Webpack Dev Middleware: Middleware which arguments a live bundle. -- Maintainer: Webpack Team
Webpack Dev Server: Serves a webpack app. Updates the browser on changes. -- Maintainer: Webpack Team
Webpack Merge - Merge designed for Webpack. -- Maintainer: Juho Vepsäläinen
NPM Install Webpack - Automatically install & save deps with Webpack. -- Maintainer: Eric Clemmons
Webpack Validator - Validates your webpack config with Joi. -- Maintainer: js-dxtools Team
Webpack Config Utils - Util. to make your webpack config easier to read. -- Maintainer: Kent C. Dodds
Read - A highly scalable react boilerplate from logustra
@route-resource-preload/webpack-plugin - Focus on improving the first screen loading speed of applications and providing the best user experience, inspiration comes from the preloading of NextJS from Devin Deng.
Vue
Vuad - A highly scalable vue boilerplate from logustra
Here you can find webpack project brand guidelines, assets, and license. See our official media repository for more information and to find the license that governs this work. Click any of the images to download them.
The Name
Webpack can be written with a capital W when used at the start of a sentence, otherwise it should be written in lower-case letters.
Logo
The webpack logo should be placed on a white background with enough space around it like this:
The following colors are used throughout the site in various combinations and on our fancy clothing line launched with the help of Open Collective and Threadless over at the official webpack store!
Color Name
HEX Code
RGB Code
Sample
Malibu:
HEX #8dd6f9
rgb: 141, 214, 249
Denim:
HEX #1d78c1
rgb: 29, 120, 193
Fiord:
HEX #465E69
rgb: 70, 94, 105
Outer Space:
HEX #2B3A42
rgb: 43, 58, 66
White:
HEX #ffffff
rgb: 255, 255, 255
Concrete:
HEX #f2f2f2
rgb: 242, 242, 242
Alto:
HEX #dedede
rgb: 222, 222, 222
Dusty Gray:
HEX #999999
rgb: 153, 153, 153
Dove Gray:
HEX #666666
rgb: 102, 102, 102
Emperor:
HEX #535353
rgb: 83, 83, 83
Mine Shaft:
HEX #333333
rgb: 51, 51, 51
In addition, you can grab the following file types directly from these links:
Webpack is not the only module bundler out there. If you are choosing between using webpack or any of the bundlers below, here is a feature-by-feature comparison on how webpack fares against the current competition.
♦ in production mode (opposite in development mode)
X is the length of the path string
Bundling vs. Loading
It's important to note some key differences between loading and bundling modules. A tool like SystemJS, which can be found under the hood of JSPM, is used to load and transpile modules at runtime in the browser. This differs significantly from webpack, where modules are transpiled (through "loaders") and bundled before hitting the browser.
Each method has its advantages and disadvantages. Loading and transpiling modules at runtime can add a lot of overhead for larger sites and applications comprised of many modules. For this reason, SystemJS makes more sense for smaller projects where fewer modules are required. However, this may change a bit as HTTP/2 will improve the speed at which files can be transferred from server to client. Note that HTTP/2 doesn't change anything about transpiling modules, which will always take longer when done client-side.
Webpack is not the only module bundler out there. If you are choosing between using webpack or any of the bundlers below, here is a feature-by-feature comparison on how webpack fares against the current competition.
♦ in production mode (opposite in development mode)
X is the length of the path string
Bundling vs. Loading
It's important to note some key differences between loading and bundling modules. A tool like SystemJS, which can be found under the hood of JSPM, is used to load and transpile modules at runtime in the browser. This differs significantly from webpack, where modules are transpiled (through "loaders") and bundled before hitting the browser.
Each method has its advantages and disadvantages. Loading and transpiling modules at runtime can add a lot of overhead for larger sites and applications comprised of many modules. For this reason, SystemJS makes more sense for smaller projects where fewer modules are required. However, this may change a bit as HTTP/2 will improve the speed at which files can be transferred from server to client. Note that HTTP/2 doesn't change anything about transpiling modules, which will always take longer when done client-side.
Any time one file depends on another, webpack treats this as a dependency. This allows webpack to take non-code assets, such as images or web fonts, and also provide them as dependencies for your application.
When webpack processes your application, it starts from a list of modules defined on the command line or in its configuration file.
-Starting from these entry points, webpack recursively builds a dependency graph that includes every module your application needs, then bundles all of those modules into a small number of bundles - often, only one - to be loaded by the browser.
Hot Module Replacement (HMR) exchanges, adds, or removes modules while an application is running, without a full reload. This can significantly speed up development in a few ways:
Retain application state which is lost during a full reload.
Save valuable development time by only updating what's changed.
Instantly update the browser when modifications are made to CSS/JS in the source code, which is almost comparable to changing styles directly in the browser's dev tools.
How It Works
Let's go through some different viewpoints to understand exactly how HMR works...
In the Application
The following steps allow modules to be swapped in and out of an application:
The application asks the HMR runtime to check for updates.
The runtime asynchronously downloads the updates and notifies the application.
The application then asks the runtime to apply the updates.
The runtime synchronously applies the updates.
You can set up HMR so that this process happens automatically, or you can choose to require user interaction for updates to occur.
In the Compiler
In addition to normal assets, the compiler needs to emit an "update" to allow updating from the previous version to the new version. The "update" consists of two parts:
The manifest contains the new compilation hash and a list of all updated chunks. Each of these chunks contains the new code for all updated modules (or a flag indicating that the module was removed).
The compiler ensures that module IDs and chunk IDs are consistent between these builds. It typically stores these IDs in memory (e.g. with webpack-dev-server), but it's also possible to store them in a JSON file.
In a Module
HMR is an opt-in feature that only affects modules containing HMR code. One example would be patching styling through the style-loader. In order for patching to work, the style-loader implements the HMR interface; when it receives an update through HMR, it replaces the old styles with the new ones.
Similarly, when implementing the HMR interface in a module, you can describe what should happen when the module is updated. However, in most cases, it's not mandatory to write HMR code in every module. If a module has no HMR handlers, the update bubbles up. This means that a single handler can update a complete module tree. If a single module from the tree is updated, the entire set of dependencies is reloaded.
See the HMR API page for details on the module.hot interface.
In the Runtime
Here things get a bit more technical... if you're not interested in the internals, feel free to jump to the HMR API page or HMR guide.
For the module system runtime, additional code is emitted to track module parents and children. On the management side, the runtime supports two methods: check and apply.
A check makes an HTTP request to the update manifest. If this request fails, there is no update available. If it succeeds, the list of updated chunks is compared to the list of currently loaded chunks. For each loaded chunk, the corresponding update chunk is downloaded. All module updates are stored in the runtime. When all update chunks have been downloaded and are ready to be applied, the runtime switches into the ready state.
The apply method flags all updated modules as invalid. For each invalid module, there needs to be an update handler in the module or in its parent(s). Otherwise, the invalid flag bubbles up and invalidates parent(s) as well. Each bubble continues until the app's entry point or a module with an update handler is reached (whichever comes first). If it bubbles up from an entry point, the process fails.
Afterwards, all invalid modules are disposed (via the dispose handler) and unloaded. The current hash is then updated and all accept handlers are called. The runtime switches back to the idle state and everything continues as normal.
Get Started
HMR can be used in development as a LiveReload replacement. webpack-dev-server supports a hot mode in which it tries to update with HMR before trying to reload the whole page. See the Hot Module Replacement guide for details.
Hot Module Replacement (HMR) exchanges, adds, or removes modules while an application is running, without a full reload. This can significantly speed up development in a few ways:
Retain application state which is lost during a full reload.
Save valuable development time by only updating what's changed.
Instantly update the browser when modifications are made to CSS/JS in the source code, which is almost comparable to changing styles directly in the browser's dev tools.
How It Works
Let's go through some different viewpoints to understand exactly how HMR works...
In the Application
The following steps allow modules to be swapped in and out of an application:
The application asks the HMR runtime to check for updates.
The runtime asynchronously downloads the updates and notifies the application.
The application then asks the runtime to apply the updates.
The runtime synchronously applies the updates.
You can set up HMR so that this process happens automatically, or you can choose to require user interaction for updates to occur.
In the Compiler
In addition to normal assets, the compiler needs to emit an "update" to allow updating from the previous version to the new version. The "update" consists of two parts:
The manifest contains the new compilation hash and a list of all updated chunks. Each of these chunks contains the new code for all updated modules (or a flag indicating that the module was removed).
The compiler ensures that module IDs and chunk IDs are consistent between these builds. It typically stores these IDs in memory (e.g. with webpack-dev-server), but it's also possible to store them in a JSON file.
In a Module
HMR is an opt-in feature that only affects modules containing HMR code. One example would be patching styling through the style-loader. In order for patching to work, the style-loader implements the HMR interface; when it receives an update through HMR, it replaces the old styles with the new ones.
Similarly, when implementing the HMR interface in a module, you can describe what should happen when the module is updated. However, in most cases, it's not mandatory to write HMR code in every module. If a module has no HMR handlers, the update bubbles up. This means that a single handler can update a complete module tree. If a single module from the tree is updated, the entire set of dependencies is reloaded.
See the HMR API page for details on the module.hot interface.
In the Runtime
Here things get a bit more technical... if you're not interested in the internals, feel free to jump to the HMR API page or HMR guide.
For the module system runtime, additional code is emitted to track module parents and children. On the management side, the runtime supports two methods: check and apply.
A check makes an HTTP request to the update manifest. If this request fails, there is no update available. If it succeeds, the list of updated chunks is compared to the list of currently loaded chunks. For each loaded chunk, the corresponding update chunk is downloaded. All module updates are stored in the runtime. When all update chunks have been downloaded and are ready to be applied, the runtime switches into the ready state.
The apply method flags all updated modules as invalid. For each invalid module, there needs to be an update handler in the module or in its parent(s). Otherwise, the invalid flag bubbles up and invalidates parent(s) as well. Each bubble continues until the app's entry point or a module with an update handler is reached (whichever comes first). If it bubbles up from an entry point, the process fails.
Afterwards, all invalid modules are disposed (via the dispose handler) and unloaded. The current hash is then updated and all accept handlers are called. The runtime switches back to the idle state and everything continues as normal.
Get Started
HMR can be used in development as a LiveReload replacement. webpack-dev-server supports a hot mode in which it tries to update with HMR before trying to reload the whole page. See the Hot Module Replacement guide for details.
In a typical application or site built with webpack, there are three main types of code:
The source code you, and maybe your team, have written.
Any third-party library or "vendor" code your source is dependent on.
A webpack runtime and manifest that conducts the interaction of all modules.
This article will focus on the last of these three parts: the runtime and, in particular, the manifest.
Runtime
The runtime, along with the manifest data, is all the code webpack needs to connect your modularized application while it's running in the browser. It contains the loading and resolving logic needed to connect your modules as they interact. This includes connecting modules that have already been loaded into the browser as well as logic to lazy-load the ones that haven't.
Manifest
Once your application hits the browser in the form of index.html file, some bundles and a variety of other assets required by your application must be loaded and linked somehow. That /src directory you meticulously laid out is now bundled, minified and maybe even split into smaller chunks for lazy-loading by webpack's optimization. So how does webpack manage the interaction between all of your required modules? This is where the manifest data comes in...
As the compiler enters, resolves, and maps out your application, it keeps detailed notes on all your modules. This collection of data is called the "Manifest," and it's what the runtime will use to resolve and load modules once they've been bundled and shipped to the browser. No matter which module syntax you have chosen, those import or require statements have now become __webpack_require__ methods that point to module identifiers. Using the data in the manifest, the runtime will be able to find out where to retrieve the modules behind the identifiers.
The Problem
So now you have a little bit of insight about how webpack works behind the scenes. "But, how does this affect me?", you might ask. Most of the time, it doesn't. The runtime will do its thing, utilizing the manifest, and everything will appear to magically work once your application hits the browser. However, if you decide to improve the performance of your projects by utilizing browser caching, this process will all of a sudden become an important thing to understand.
By using content hashes within your bundle file names, you can indicate to the browser when the content of a file has changed, thus invalidating the cache. Once you start doing this though, you'll immediately notice some funny behavior. Certain hashes change even when their content apparently does not. This is caused by the injection of the runtime and manifest, which changes every build.
See the manifest section of our Output management guide to learn how to extract the manifest, and read the guides below to learn more about the intricacies of long term caching.
In a typical application or site built with webpack, there are three main types of code:
The source code you, and maybe your team, have written.
Any third-party library or "vendor" code your source is dependent on.
A webpack runtime and manifest that conducts the interaction of all modules.
This article will focus on the last of these three parts: the runtime and, in particular, the manifest.
Runtime
The runtime, along with the manifest data, is all the code webpack needs to connect your modularized application while it's running in the browser. It contains the loading and resolving logic needed to connect your modules as they interact. This includes connecting modules that have already been loaded into the browser as well as logic to lazy-load the ones that haven't.
Manifest
Once your application hits the browser in the form of index.html file, some bundles and a variety of other assets required by your application must be loaded and linked somehow. That /src directory you meticulously laid out is now bundled, minified and maybe even split into smaller chunks for lazy-loading by webpack's optimization. So how does webpack manage the interaction between all of your required modules? This is where the manifest data comes in...
As the compiler enters, resolves, and maps out your application, it keeps detailed notes on all your modules. This collection of data is called the "Manifest," and it's what the runtime will use to resolve and load modules once they've been bundled and shipped to the browser. No matter which module syntax you have chosen, those import or require statements have now become __webpack_require__ methods that point to module identifiers. Using the data in the manifest, the runtime will be able to find out where to retrieve the modules behind the identifiers.
The Problem
So now you have a little bit of insight about how webpack works behind the scenes. "But, how does this affect me?", you might ask. Most of the time, it doesn't. The runtime will do its thing, utilizing the manifest, and everything will appear to magically work once your application hits the browser. However, if you decide to improve the performance of your projects by utilizing browser caching, this process will all of a sudden become an important thing to understand.
By using content hashes within your bundle file names, you can indicate to the browser when the content of a file has changed, thus invalidating the cache. Once you start doing this though, you'll immediately notice some funny behavior. Certain hashes change even when their content apparently does not. This is caused by the injection of the runtime and manifest, which changes every build.
See the manifest section of our Output management guide to learn how to extract the manifest, and read the guides below to learn more about the intricacies of long term caching.
To understand why you should use webpack, let's recap how we used JavaScript on the web before bundlers were a thing.
There are two ways to run JavaScript in a browser. First, include a script for each functionality; this solution is hard to scale because loading too many scripts can cause a network bottleneck. The second option is to use a big .js file containing all your project code, but this leads to problems in scope, size, readability and maintainability.
IIFEs - Immediately invoked function expressions
IIFEs solve scoping issues for large projects; when script files are wrapped by an IIFE, you can safely concatenate or safely combine files without worrying about scope collision.
The use of IIFEs led to tools like Make, Gulp, Grunt, Broccoli or Brunch. These tools are known as task runners, and they concatenate all your project files together.
However, changing one file means you have to rebuild the whole thing. Concatenating makes it easier to reuse scripts across files but makes build optimizations more difficult. How can you find out if code is actually being used or not?
Even if you only use a single function from lodash, you have to add the entire library and then squish it together. How do you treeshake the dependencies on your code? Lazy loading chunks of code can be hard to do at scale and requires a lot of manual work from the developer.
Birth of JavaScript Modules happened thanks to Node.js
Webpack runs on Node.js, a JavaScript runtime that can be used in computers and servers outside a browser environment.
When Node.js was released a new era started, and it came with new challenges. Now that JavaScript is not running in a browser, how are Node applications supposed to load new chunks of code? There are no html files and script tags that can be added to it.
CommonJS came out and introduced require, which allows you to load and use a module in the current file. This solved scope issues out of the box by importing each module as it was needed.
npm + Node.js + modules – mass distribution
JavaScript is taking over the world as a language, as a platform and as a way to rapidly develop and create fast applications.
But there is no browser support for CommonJS. There are no live bindings. There are problems with circular references. Synchronous module resolution and loading is slow. While CommonJS was a great solution for Node.js projects, browsers didn't support modules, so bundlers and tools like Browserify, RequireJS and SystemJS were created, allowing us to write CommonJS modules that run in a browser.
ESM - ECMAScript Modules
The good news for web projects is that modules are becoming an official feature in the ECMAScript standard. However, browser support is incomplete and bundling is still faster and currently recommended over these early module implementations.
Automatic Dependency Collection
Old school Task Runners and even Google Closure Compiler requires you to manually declare all dependencies upfront. While bundlers like webpack automatically build and infer your dependency graph based on what is imported and exported. This along with other plugins and loaders make for a great developer experience.
Wouldn't it be nice…
...to have something that will not only let us write modules but also support any module format (at least until we get to ESM) and handle resources and assets at the same time?
This is why webpack exists. It's a tool that lets you bundle your JavaScript applications (supporting both ESM and CommonJS), and it can be extended to support many different assets such as images, fonts and stylesheets.
Webpack cares about performance and load times; it's always improving or adding new features, such as async chunk loading and prefetching, to deliver the best possible experience for your project and your users.
To understand why you should use webpack, let's recap how we used JavaScript on the web before bundlers were a thing.
There are two ways to run JavaScript in a browser. First, include a script for each functionality; this solution is hard to scale because loading too many scripts can cause a network bottleneck. The second option is to use a big .js file containing all your project code, but this leads to problems in scope, size, readability and maintainability.
IIFEs - Immediately invoked function expressions
IIFEs solve scoping issues for large projects; when script files are wrapped by an IIFE, you can safely concatenate or safely combine files without worrying about scope collision.
The use of IIFEs led to tools like Make, Gulp, Grunt, Broccoli or Brunch. These tools are known as task runners, and they concatenate all your project files together.
However, changing one file means you have to rebuild the whole thing. Concatenating makes it easier to reuse scripts across files but makes build optimizations more difficult. How can you find out if code is actually being used or not?
Even if you only use a single function from lodash, you have to add the entire library and then squish it together. How do you treeshake the dependencies on your code? Lazy loading chunks of code can be hard to do at scale and requires a lot of manual work from the developer.
Birth of JavaScript Modules happened thanks to Node.js
Webpack runs on Node.js, a JavaScript runtime that can be used in computers and servers outside a browser environment.
When Node.js was released a new era started, and it came with new challenges. Now that JavaScript is not running in a browser, how are Node applications supposed to load new chunks of code? There are no html files and script tags that can be added to it.
CommonJS came out and introduced require, which allows you to load and use a module in the current file. This solved scope issues out of the box by importing each module as it was needed.
npm + Node.js + modules – mass distribution
JavaScript is taking over the world as a language, as a platform and as a way to rapidly develop and create fast applications.
But there is no browser support for CommonJS. There are no live bindings. There are problems with circular references. Synchronous module resolution and loading is slow. While CommonJS was a great solution for Node.js projects, browsers didn't support modules, so bundlers and tools like Browserify, RequireJS and SystemJS were created, allowing us to write CommonJS modules that run in a browser.
ESM - ECMAScript Modules
The good news for web projects is that modules are becoming an official feature in the ECMAScript standard. However, browser support is incomplete and bundling is still faster and currently recommended over these early module implementations.
Automatic Dependency Collection
Old school Task Runners and even Google Closure Compiler requires you to manually declare all dependencies upfront. While bundlers like webpack automatically build and infer your dependency graph based on what is imported and exported. This along with other plugins and loaders make for a great developer experience.
Wouldn't it be nice…
...to have something that will not only let us write modules but also support any module format (at least until we get to ESM) and handle resources and assets at the same time?
This is why webpack exists. It's a tool that lets you bundle your JavaScript applications (supporting both ESM and CommonJS), and it can be extended to support many different assets such as images, fonts and stylesheets.
Webpack cares about performance and load times; it's always improving or adding new features, such as async chunk loading and prefetching, to deliver the best possible experience for your project and your users.
Choose a style of source mapping to enhance the debugging process. These values can affect build and rebuild speed dramatically.
devtool
performance
production
quality
comment
(none)
build: fastest
rebuild: fastest
yes
bundle
Recommended choice for production builds with maximum performance.
eval
build: fast
rebuild: fastest
no
generated
Recommended choice for development builds with maximum performance.
eval-cheap-source-map
build: ok
rebuild: fast
no
transformed
Tradeoff choice for development builds.
eval-cheap-module-source-map
build: slow
rebuild: fast
no
original lines
Tradeoff choice for development builds.
eval-source-map
build: slowest
rebuild: ok
no
original
Recommended choice for development builds with high quality SourceMaps.
cheap-source-map
build: ok
rebuild: slow
no
transformed
cheap-module-source-map
build: slow
rebuild: slow
no
original lines
source-map
build: slowest
rebuild: slowest
yes
original
Recommended choice for production builds with high quality SourceMaps.
inline-cheap-source-map
build: ok
rebuild: slow
no
transformed
inline-cheap-module-source-map
build: slow
rebuild: slow
no
original lines
inline-source-map
build: slowest
rebuild: slowest
no
original
Possible choice when publishing a single file
eval-nosources-cheap-source-map
build: ok
rebuild: fast
no
transformed
source code not included
eval-nosources-cheap-module-source-map
build: slow
rebuild: fast
no
original lines
source code not included
eval-nosources-source-map
build: slowest
rebuild: ok
no
original
source code not included
inline-nosources-cheap-source-map
build: ok
rebuild: slow
no
transformed
source code not included
inline-nosources-cheap-module-source-map
build: slow
rebuild: slow
no
original lines
source code not included
inline-nosources-source-map
build: slowest
rebuild: slowest
no
original
source code not included
nosources-cheap-source-map
build: ok
rebuild: slow
no
transformed
source code not included
nosources-cheap-module-source-map
build: slow
rebuild: slow
no
original lines
source code not included
nosources-source-map
build: slowest
rebuild: slowest
yes
original
source code not included
hidden-nosources-cheap-source-map
build: ok
rebuild: slow
no
transformed
no reference, source code not included
hidden-nosources-cheap-module-source-map
build: slow
rebuild: slow
no
original lines
no reference, source code not included
hidden-nosources-source-map
build: slowest
rebuild: slowest
yes
original
no reference, source code not included
hidden-cheap-source-map
build: ok
rebuild: slow
no
transformed
no reference
hidden-cheap-module-source-map
build: slow
rebuild: slow
no
original lines
no reference
hidden-source-map
build: slowest
rebuild: slowest
yes
original
no reference. Possible choice when using SourceMap only for error reporting purposes.
shortcut
explanation
performance: build
How is the performance of the initial build affected by the devtool setting?
performance: rebuild
How is the performance of the incremental build affected by the devtool setting? Slow devtools might reduce development feedback loop in watch mode. The scale is different compared to the build performance, as one would expect rebuilds to be faster than builds.
production
Does it make sense to use this devtool for production builds? It's usually no when the devtool has a negative effect on user experience.
quality: bundled
You will see all generated code of a chunk in a single blob of code. This is the raw output file without any devtooling support
quality: generated
You will see the generated code, but each module is shown as separate code file in browser devtools.
quality: transformed
You will see generated code after the preprocessing by loaders but before additional webpack transformations. Only source lines will be mapped and column information will be discarded resp. not generated. This prevents setting breakpoints in the middle of lines which doesn't work together with minimizer.
quality: original lines
You will see the original code that you wrote, assuming all loaders support SourceMapping. Only source lines will be mapped and column information will be discarded resp. not generated. This prevents setting breakpoints in the middle of lines which doesn't work together with minimizer.
quality: original
You will see the original code that you wrote, assuming all loaders support SourceMapping.
eval-* addition
generate SourceMap per module and attach it via eval. Recommended for development, because of improved rebuild performance. Note that there is a windows defender issue, which causes huge slowdown due to virus scanning.
inline-* addition
inline the SourceMap to the original file instead of creating a separate file.
hidden-* addition
no reference to the SourceMap added. When SourceMap is not deployed, but should still be generated, e. g. for error reporting purposes.
nosources-* addition
source code is not included in SourceMap. This can be useful when the original files should be referenced (further config options needed).
Some of these values are suited for development and some for production. For development you typically want fast Source Maps at the cost of bundle size, but for production you want separate Source Maps that are accurate and support minimizing.
Qualities
bundled code - You see all generated code as a big blob of code. You don't see modules separated from each other.
generated code - You see each module separated from each other, annotated with module names. You see the code generated by webpack. Example: Instead of import {test} from "module"; test(); you see something like var module__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(42); module__WEBPACK_IMPORTED_MODULE_1__.a();.
transformed code - You see each module separated from each other, annotated with module names. You see the code before webpack transforms it, but after Loaders transpile it. Example: Instead of import {test} from "module"; class A extends test {} you see something like import {test} from "module"; var A = function(_test) { ... }(test);
original source - You see each module separated from each other, annotated with module names. You see the code before transpilation, as you authored it. This depends on Loader support.
without source content - Contents for the sources are not included in the Source Maps. Browsers usually try to load the source from the webserver or filesystem. You have to make sure to set output.devtoolModuleFilenameTemplate correctly to match source urls.
(lines only) - Source Maps are simplified to a single mapping per line. This usually means a single mapping per statement (assuming you author it this way). This prevents you from debugging execution on statement level and from settings breakpoints on columns of a line. Combining with minimizing is not possible as minimizers usually only emit a single line.
Development
The following options are ideal for development:
eval - Each module is executed with eval() and //# sourceURL. This is pretty fast. The main disadvantage is that it doesn't display line numbers correctly since it gets mapped to transpiled code instead of the original code (No Source Maps from Loaders).
eval-source-map - Each module is executed with eval() and a SourceMap is added as a DataUrl to the eval(). Initially it is slow, but it provides fast rebuild speed and yields real files. Line numbers are correctly mapped since it gets mapped to the original code. It yields the best quality SourceMaps for development.
eval-cheap-source-map - Similar to eval-source-map, each module is executed with eval(). It is "cheap" because it doesn't have column mappings, it only maps line numbers. It ignores SourceMaps from Loaders and only display transpiled code similar to the eval devtool.
eval-cheap-module-source-map - Similar to eval-cheap-source-map, however, in this case Source Maps from Loaders are processed for better results. However Loader Source Maps are simplified to a single mapping per line.
Special cases
The following options are not ideal for development nor production. They are needed for some special cases, i. e. for some 3rd party tools.
inline-source-map - A SourceMap is added as a DataUrl to the bundle.
cheap-source-map - A SourceMap without column-mappings ignoring loader Source Maps.
inline-cheap-source-map - Similar to cheap-source-map but SourceMap is added as a DataUrl to the bundle.
cheap-module-source-map - A SourceMap without column-mappings that simplifies loader Source Maps to a single mapping per line.
inline-cheap-module-source-map - Similar to cheap-module-source-map but SourceMap is added as a DataUrl to the bundle.
Production
These options are typically used in production:
(none) (Omit the devtool option) - No SourceMap is emitted. This is a good option to start with.
source-map - A full SourceMap is emitted as a separate file. It adds a reference comment to the bundle so development tools know where to find it.
hidden-source-map - Same as source-map, but doesn't add a reference comment to the bundle. Useful if you only want SourceMaps to map error stack traces from error reports, but don't want to expose your SourceMap for the browser development tools.
nosources-source-map - A SourceMap is created without the sourcesContent in it. It can be used to map stack traces on the client without exposing all of the source code. You can deploy the Source Map file to the webserver.
Choose a style of source mapping to enhance the debugging process. These values can affect build and rebuild speed dramatically.
devtool
performance
production
quality
comment
(none)
build: fastest
rebuild: fastest
yes
bundle
Recommended choice for production builds with maximum performance.
eval
build: fast
rebuild: fastest
no
generated
Recommended choice for development builds with maximum performance.
eval-cheap-source-map
build: ok
rebuild: fast
no
transformed
Tradeoff choice for development builds.
eval-cheap-module-source-map
build: slow
rebuild: fast
no
original lines
Tradeoff choice for development builds.
eval-source-map
build: slowest
rebuild: ok
no
original
Recommended choice for development builds with high quality SourceMaps.
cheap-source-map
build: ok
rebuild: slow
no
transformed
cheap-module-source-map
build: slow
rebuild: slow
no
original lines
source-map
build: slowest
rebuild: slowest
yes
original
Recommended choice for production builds with high quality SourceMaps.
inline-cheap-source-map
build: ok
rebuild: slow
no
transformed
inline-cheap-module-source-map
build: slow
rebuild: slow
no
original lines
inline-source-map
build: slowest
rebuild: slowest
no
original
Possible choice when publishing a single file
eval-nosources-cheap-source-map
build: ok
rebuild: fast
no
transformed
source code not included
eval-nosources-cheap-module-source-map
build: slow
rebuild: fast
no
original lines
source code not included
eval-nosources-source-map
build: slowest
rebuild: ok
no
original
source code not included
inline-nosources-cheap-source-map
build: ok
rebuild: slow
no
transformed
source code not included
inline-nosources-cheap-module-source-map
build: slow
rebuild: slow
no
original lines
source code not included
inline-nosources-source-map
build: slowest
rebuild: slowest
no
original
source code not included
nosources-cheap-source-map
build: ok
rebuild: slow
no
transformed
source code not included
nosources-cheap-module-source-map
build: slow
rebuild: slow
no
original lines
source code not included
nosources-source-map
build: slowest
rebuild: slowest
yes
original
source code not included
hidden-nosources-cheap-source-map
build: ok
rebuild: slow
no
transformed
no reference, source code not included
hidden-nosources-cheap-module-source-map
build: slow
rebuild: slow
no
original lines
no reference, source code not included
hidden-nosources-source-map
build: slowest
rebuild: slowest
yes
original
no reference, source code not included
hidden-cheap-source-map
build: ok
rebuild: slow
no
transformed
no reference
hidden-cheap-module-source-map
build: slow
rebuild: slow
no
original lines
no reference
hidden-source-map
build: slowest
rebuild: slowest
yes
original
no reference. Possible choice when using SourceMap only for error reporting purposes.
shortcut
explanation
performance: build
How is the performance of the initial build affected by the devtool setting?
performance: rebuild
How is the performance of the incremental build affected by the devtool setting? Slow devtools might reduce development feedback loop in watch mode. The scale is different compared to the build performance, as one would expect rebuilds to be faster than builds.
production
Does it make sense to use this devtool for production builds? It's usually no when the devtool has a negative effect on user experience.
quality: bundled
You will see all generated code of a chunk in a single blob of code. This is the raw output file without any devtooling support
quality: generated
You will see the generated code, but each module is shown as separate code file in browser devtools.
quality: transformed
You will see generated code after the preprocessing by loaders but before additional webpack transformations. Only source lines will be mapped and column information will be discarded resp. not generated. This prevents setting breakpoints in the middle of lines which doesn't work together with minimizer.
quality: original lines
You will see the original code that you wrote, assuming all loaders support SourceMapping. Only source lines will be mapped and column information will be discarded resp. not generated. This prevents setting breakpoints in the middle of lines which doesn't work together with minimizer.
quality: original
You will see the original code that you wrote, assuming all loaders support SourceMapping.
eval-* addition
generate SourceMap per module and attach it via eval. Recommended for development, because of improved rebuild performance. Note that there is a windows defender issue, which causes huge slowdown due to virus scanning.
inline-* addition
inline the SourceMap to the original file instead of creating a separate file.
hidden-* addition
no reference to the SourceMap added. When SourceMap is not deployed, but should still be generated, e. g. for error reporting purposes.
nosources-* addition
source code is not included in SourceMap. This can be useful when the original files should be referenced (further config options needed).
Some of these values are suited for development and some for production. For development you typically want fast Source Maps at the cost of bundle size, but for production you want separate Source Maps that are accurate and support minimizing.
Qualities
bundled code - You see all generated code as a big blob of code. You don't see modules separated from each other.
generated code - You see each module separated from each other, annotated with module names. You see the code generated by webpack. Example: Instead of import {test} from "module"; test(); you see something like var module__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(42); module__WEBPACK_IMPORTED_MODULE_1__.a();.
transformed code - You see each module separated from each other, annotated with module names. You see the code before webpack transforms it, but after Loaders transpile it. Example: Instead of import {test} from "module"; class A extends test {} you see something like import {test} from "module"; var A = function(_test) { ... }(test);
original source - You see each module separated from each other, annotated with module names. You see the code before transpilation, as you authored it. This depends on Loader support.
without source content - Contents for the sources are not included in the Source Maps. Browsers usually try to load the source from the webserver or filesystem. You have to make sure to set output.devtoolModuleFilenameTemplate correctly to match source urls.
(lines only) - Source Maps are simplified to a single mapping per line. This usually means a single mapping per statement (assuming you author it this way). This prevents you from debugging execution on statement level and from settings breakpoints on columns of a line. Combining with minimizing is not possible as minimizers usually only emit a single line.
Development
The following options are ideal for development:
eval - Each module is executed with eval() and //# sourceURL. This is pretty fast. The main disadvantage is that it doesn't display line numbers correctly since it gets mapped to transpiled code instead of the original code (No Source Maps from Loaders).
eval-source-map - Each module is executed with eval() and a SourceMap is added as a DataUrl to the eval(). Initially it is slow, but it provides fast rebuild speed and yields real files. Line numbers are correctly mapped since it gets mapped to the original code. It yields the best quality SourceMaps for development.
eval-cheap-source-map - Similar to eval-source-map, each module is executed with eval(). It is "cheap" because it doesn't have column mappings, it only maps line numbers. It ignores SourceMaps from Loaders and only display transpiled code similar to the eval devtool.
eval-cheap-module-source-map - Similar to eval-cheap-source-map, however, in this case Source Maps from Loaders are processed for better results. However Loader Source Maps are simplified to a single mapping per line.
Special cases
The following options are not ideal for development nor production. They are needed for some special cases, i. e. for some 3rd party tools.
inline-source-map - A SourceMap is added as a DataUrl to the bundle.
cheap-source-map - A SourceMap without column-mappings ignoring loader Source Maps.
inline-cheap-source-map - Similar to cheap-source-map but SourceMap is added as a DataUrl to the bundle.
cheap-module-source-map - A SourceMap without column-mappings that simplifies loader Source Maps to a single mapping per line.
inline-cheap-module-source-map - Similar to cheap-module-source-map but SourceMap is added as a DataUrl to the bundle.
Production
These options are typically used in production:
(none) (Omit the devtool option) - No SourceMap is emitted. This is a good option to start with.
source-map - A full SourceMap is emitted as a separate file. It adds a reference comment to the bundle so development tools know where to find it.
hidden-source-map - Same as source-map, but doesn't add a reference comment to the bundle. Useful if you only want SourceMaps to map error stack traces from error reports, but don't want to expose your SourceMap for the browser development tools.
nosources-source-map - A SourceMap is created without the sourcesContent in it. It can be used to map stack traces on the client without exposing all of the source code. You can deploy the Source Map file to the webserver.
When contributing to the core repo, writing a loader/plugin, or even working on a complex project, debugging tools can be central to your workflow. Whether the problem is slow performance on a large project or an unhelpful traceback, the following utilities can make figuring it out less painful.
Whether you want to sift through this data manually or use a tool to process it, the stats data can be extremely useful when debugging build issues. We won't go in depth here as there's an entire page dedicated to its contents, but know that you can use it to find the following information:
The contents of every module.
The modules contained within every chunk.
Per module compilation and resolving stats.
Build errors and warnings.
The relationships between modules.
And much more...
On top of that, the official analyze tool and various others will accept this data and visualize it in various ways.
DevTools
While console statements may work well in straightforward scenarios, sometimes a more robust solution is needed. As most front-end developers already know, Chrome DevTools are a life saver when debugging web applications, but they don’t have to stop there. As of Node v6.3.0+, developers can use the built-in --inspect flag to debug a node program in DevTools.
Let's start by invoking webpack with the node --inspect.
Note that we cannot run npm scripts, e.g. npm run build, so we'll have to specify the full node_modules path:
Debugger listening on ws://127.0.0.1:9229/c624201a-250f-416e-a018-300bbec7be2c
-For help see https://nodejs.org/en/docs/inspector
Now jump to chrome://inspect in the browser and you should see any active scripts you've inspected under the Remote Target header. Click the "inspect" link under each script to open a dedicated debugger or the Open dedicated DevTools for Node link for a session that will connect automatically. You can also check out the NiM extension, a handy Chrome plugin that will automatically open a DevTools tab every time you --inspect a script.
We recommend using the --inspect-brk flag which will break on the first statement of the script allowing you to go through the source to set breakpoints and start/stop the build as you please. Also, don't forget that you can still pass arguments to the script. For example, if you have multiple configuration files you could pass --config webpack.prod.js to specify the configuration you'd like to debug.
The people who contribute to webpack do so for the love of open source, our users and ecosystem, and most importantly, pushing the web forward together. Because of our Open Collective model for funding and transparency, we are able to funnel support and funds through contributors, dependent projects, and the contributor and core teams. To make a donation, click the button below...
But what is the return on the investment?
Developers
The biggest core feature we'd like to provide is an enjoyable development experience. Developers like you can help by contributing to rich and vibrant documentation, issuing pull requests to help us cover niche use cases, and to help sustain what you love about webpack.
How Can I Help?
Anybody can help by doing any of the following:
Ask your employer to use webpack in projects.
Help us write and maintain the content on this site (see the writer's guide).
You can ask your employer to improve your workflow by leveraging webpack: an all-in-one tool for fonts, images and image optimization, and json. Explain to them how webpack will attempt to bundle your code and assets the best it can for the smallest file size, leading to speedier sites and applications.
Your Contributions
Contributing to webpack is not contributing to an exclusive club. You as a developer are contributing to the overall health of downstream projects. Hundreds, if not thousands, of projects depend on webpack and contributing will make the ecosystem better for all the users.
The remainder of this section of the site is dedicated to developers such as yourself who would like to become a part of our ever-growing community:
Webpack is an all-in-one tool for bundling your code. It can handle fonts, images, data and more with the help of community-driven plugins and loaders. Having all of your assets be handled by one tool is immensely helpful, as you or your team can spend less time making sure a machine with many moving parts is working correctly and more time building your product.
Sponsorship
Aside from monetary assistance, companies can support webpack by:
Providing developers that are not actively working on a project.
Contributing computing power for improved CI and regression testing.
You can also encourage your developers to contribute to the ecosystem by open-sourcing webpack loaders, plugins and other utilities. And, as mentioned above, we would greatly appreciate any help in increasing our CI/CD infrastructure.
Anyone Else
To anyone else who is interested in helping our mission – e.g. venture capitalists, government entities, digital agencies, etc. – we would love for you to work with us, one of the top npm packages, to improve your product! Please don't hesitate to reach out with questions.
Pull requests
Documentation of webpack features and changes is now being updated as webpack evolves. An automated issue creation integration was established and proven to be effective in the recent years.
When a feature gets merged, an issue with a documentation request is created in our repository and we expect to resolve it in a timely manner. This means that there are features, changes and breaking changes awaiting to be documented, reviewed and released. That said, if Pull Request's author is abandoning it for more than 30 days, we may mark such Pull Request as stale. We may take over the work that is needed to finish it.
-If Pull Request author grants write access to their fork to the webpack Documentation team we will commit directly to your branch and finish the work. In other cases, we may have to start over by ourselves or by delegating it to willing community members. This may render your Pull Request redundant and it might get closed as a part of the cleanup process.
The release process for deploying webpack is actually quite painless. Read through the following steps, so you have a clear understanding of how it's done.
Pull Requests
When merging pull requests into the main branch, select the Create Merge Commit option.
Releasing
npm version patch &&git push --follow-tags &&npm publish
npm version minor &&git push --follow-tags &&npm publish
-npm version major &&git push --follow-tags &&npm publish
This will increment the package version, commits the changes, cuts a local tag, push to github & publish the npm package.
After that go to the github releases page and write a Changelog for the new tag.
This index lists common terms used throughout the webpack ecosystem.
A
Asset: This is a general term for the images, fonts, media, and any other kind of files that are typically used in websites and other applications. These typically end up as individual files within the output but can also be inlined via things like the style-loader or url-loader.
B
Bundle: Produced from a number of distinct modules, bundles contain the final versions of source files that have already undergone the loading and compilation process.
Bundle Splitting: This process offers one way of optimizing a build, allowing webpack to generate multiple bundles for a single application. As a result, each bundle can be isolated from changes effecting others, reducing the amount of code that needs to be republished and therefore re-downloaded by the client and taking advantage of browser caching.
C
Chunk: This webpack-specific term is used internally to manage the bundling process. Bundles are composed out of chunks, of which there are several types (e.g. entry and child). Typically, chunks directly correspond with the output bundles however, there are some configurations that don't yield a one-to-one relationship.
Code Splitting: Refers to dividing your code into various bundles/chunks which you can then load on demand instead of loading a single bundle containing everything.
Configuration: webpack configuration file is a plain old JavaScript file that exports an object. This object is then processed by webpack based upon its defined properties.
D
Dependency Graph: Any time one file depends on another, webpack treats this as a dependency. Starting from an entry point(s), webpack recursively builds a dependency graph that includes every module/asset your application needs.
E
Entry Point: The entry point tells webpack where to start and follows the graph of dependencies to know what to bundle. You can think of your application's entry point(s) as the contextual root(s) of what you want bundled.
H
Hot Module Replacement (HMR): A process that exchanges, adds, or removes modules while an application is running without a full page reload.
L
Loaders: Transformations that are applied on the source code of a module. They allow you to pre-process files as you require() or "load" them. Similar to a 'task-runner'.
Lazy Loading: A process of loading parts (chunks) of your application lazily. In other words loading them only when we really need them.
M
Module: Discrete chunks of functionality that provide a smaller surface area than a full program. Well-written modules provide solid abstractions and encapsulation boundaries which make up a coherent design and clear purpose.
Module Resolution: A module can be required as a dependency from another module and a resolver is a library which helps in locating a module by its absolute path. Modules are searched for inside all directories specified in resolve.modules.
Manifest: The runtime will use it to resolve and load modules once they've been bundled and shipped to the browser.
O
Output: Option(s) specifying where to output the compiled files to disk.
Note, that while there can be multiple entry points, only one output configuration is specified.
P
Plugin: A JavaScript object that has an apply property. This apply property is called by the webpack compiler, giving access to the entire compilation lifecycle. These packages will typically extend compilation functionality in one way or another.
R
Request: Refers to the expression in the require/import statement, e.g. require("./template/" + name + ".ejs"), the request is "./template/" + name + ".ejs".
S
Shimming: Not all JS files can be used directly with webpack. The file maybe in an unsupported module format, or not even in any module format. It is here where shimming comes into play.
T
Target: User configured deployment target(s) listed here to compile for a specific environment like the browser, NodeJS, or Electron.
Tree Shaking: Unused/Excess code elimination, or more precisely, live code importing. Compilers like webpack will accomplish this by analyzing the various kinds import statements and usage of the imported code to determine what parts of dependencies are actually being utilized, dropping parts of the "tree" that are not.
V
Vendor Entry Point: Create dependency graphs starting at both app.js and vendors.js. These graphs are completely separate and independent of each other to allow leverage of CommonsChunkPlugin and extract any vendor references from your app bundle into your vendor bundle. Helps achieve a common pattern in webpack known as long-term vendor-caching.
W
webpack: A highly configurable module bundler for modern JavaScript applications.
This index lists common terms used throughout the webpack ecosystem.
A
Asset: This is a general term for the images, fonts, media, and any other kind of files that are typically used in websites and other applications. These typically end up as individual files within the output but can also be inlined via things like the style-loader or url-loader.
B
Bundle: Produced from a number of distinct modules, bundles contain the final versions of source files that have already undergone the loading and compilation process.
Bundle Splitting: This process offers one way of optimizing a build, allowing webpack to generate multiple bundles for a single application. As a result, each bundle can be isolated from changes effecting others, reducing the amount of code that needs to be republished and therefore re-downloaded by the client and taking advantage of browser caching.
C
Chunk: This webpack-specific term is used internally to manage the bundling process. Bundles are composed out of chunks, of which there are several types (e.g. entry and child). Typically, chunks directly correspond with the output bundles however, there are some configurations that don't yield a one-to-one relationship.
Code Splitting: Refers to dividing your code into various bundles/chunks which you can then load on demand instead of loading a single bundle containing everything.
Configuration: webpack configuration file is a plain old JavaScript file that exports an object. This object is then processed by webpack based upon its defined properties.
D
Dependency Graph: Any time one file depends on another, webpack treats this as a dependency. Starting from an entry point(s), webpack recursively builds a dependency graph that includes every module/asset your application needs.
E
Entry Point: The entry point tells webpack where to start and follows the graph of dependencies to know what to bundle. You can think of your application's entry point(s) as the contextual root(s) of what you want bundled.
H
Hot Module Replacement (HMR): A process that exchanges, adds, or removes modules while an application is running without a full page reload.
L
Loaders: Transformations that are applied on the source code of a module. They allow you to pre-process files as you require() or "load" them. Similar to a 'task-runner'.
Lazy Loading: A process of loading parts (chunks) of your application lazily. In other words loading them only when we really need them.
M
Module: Discrete chunks of functionality that provide a smaller surface area than a full program. Well-written modules provide solid abstractions and encapsulation boundaries which make up a coherent design and clear purpose.
Module Resolution: A module can be required as a dependency from another module and a resolver is a library which helps in locating a module by its absolute path. Modules are searched for inside all directories specified in resolve.modules.
Manifest: The runtime will use it to resolve and load modules once they've been bundled and shipped to the browser.
O
Output: Option(s) specifying where to output the compiled files to disk.
Note, that while there can be multiple entry points, only one output configuration is specified.
P
Plugin: A JavaScript object that has an apply property. This apply property is called by the webpack compiler, giving access to the entire compilation lifecycle. These packages will typically extend compilation functionality in one way or another.
R
Request: Refers to the expression in the require/import statement, e.g. require("./template/" + name + ".ejs"), the request is "./template/" + name + ".ejs".
S
Shimming: Not all JS files can be used directly with webpack. The file maybe in an unsupported module format, or not even in any module format. It is here where shimming comes into play.
T
Target: User configured deployment target(s) listed here to compile for a specific environment like the browser, NodeJS, or Electron.
Tree Shaking: Unused/Excess code elimination, or more precisely, live code importing. Compilers like webpack will accomplish this by analyzing the various kinds import statements and usage of the imported code to determine what parts of dependencies are actually being utilized, dropping parts of the "tree" that are not.
V
Vendor Entry Point: Create dependency graphs starting at both app.js and vendors.js. These graphs are completely separate and independent of each other to allow leverage of CommonsChunkPlugin and extract any vendor references from your app bundle into your vendor bundle. Helps achieve a common pattern in webpack known as long-term vendor-caching.
W
webpack: A highly configurable module bundler for modern JavaScript applications.
Webpack is capable of adding a nonce to all scripts that it loads. To activate this feature, set a __webpack_nonce__ variable and include it in your entry script. A unique hash-based nonce will then be generated and provided for each unique page view (this is why __webpack_nonce__ is specified in the entry file and not in the configuration). Please note that the __webpack_nonce__ should always be a base64-encoded string.
Please note that CSPs are not enabled by default. A corresponding header Content-Security-Policy or meta tag <meta http-equiv="Content-Security-Policy" ...> needs to be sent with the document to instruct the browser to enable the CSP. Here's an example of what a CSP header including a CDN white-listed URL might look like:
For more information on CSP and nonce attribute, please refer to Further Reading section at the bottom of this page.
Trusted Types
Webpack is also capable of using Trusted Types to load dynamically constructed scripts, to adhere to CSP require-trusted-types-for directive restrictions. See output.trustedTypes configuration option.
This section contains guides for understanding and mastering the wide variety of tools and features that webpack offers. The first is a guide that takes you through getting started.
The guides get more advanced as you go on. Most serve as a starting point, and once completed you should feel more comfortable diving into the actual documentation.
This section contains guides for understanding and mastering the wide variety of tools and features that webpack offers. The first is a guide that takes you through getting started.
The guides get more advanced as you go on. Most serve as a starting point, and once completed you should feel more comfortable diving into the actual documentation.
Webpack enables use of loaders to preprocess files. This allows you to bundle any static resource way beyond JavaScript. You can easily write your own loaders using Node.js.
Loaders are activated by using loadername! prefixes in require() statements, or are automatically applied via regex from your webpack configuration – see configuration.
Files
val-loader Executes code as module and consider exports as JS code
ref-loader Create dependencies between any files manually
Webpack enables use of loaders to preprocess files. This allows you to bundle any static resource way beyond JavaScript. You can easily write your own loaders using Node.js.
Loaders are activated by using loadername! prefixes in require() statements, or are automatically applied via regex from your webpack configuration – see configuration.
Files
val-loader Executes code as module and consider exports as JS code
ref-loader Create dependencies between any files manually
The NoEmitOnErrorsPlugin allows you to avoid emitting assets when there are any errors. Enabled by default, you can disable using optimization.emitOnErrors
The AutomaticPrefetchPlugin discovers all modules from the previous compilation upfront while watching for changes, trying to improve the incremental build times. Compared to PrefetchPlugin which discovers a single module upfront.
The ContextExclusionPlugin allows you to exclude context. Provide RegExp as an argument when initializing the Plugin to exclude all context that matches it.
Prefetch normal module requests, causing them to be resolved and built before the first import or require of that module occurs. Using this plugin can boost performance. Try to profile the build first to determine clever prefetching points.
Prefetch normal module requests, causing them to be resolved and built before the first import or require of that module occurs. Using this plugin can boost performance. Try to profile the build first to determine clever prefetching points.
Generate Chrome profile file which includes timings of plugins execution. Outputs events.json file by default. It is possible to provide custom file path using outputPath option.
Note : ProfilingPlugin accepts only absolute paths.
Options
outputPath: An absolute path to a custom output file (json)
\ No newline at end of file
diff --git a/api/compilation-hooks/index.html b/api/compilation-hooks/index.html
index 6796c1d9c77f..4b63b6eb24c2 100644
--- a/api/compilation-hooks/index.html
+++ b/api/compilation-hooks/index.html
@@ -89,4 +89,4 @@
// @todo: do something with "pathname", "source" and "assetInfo"});}
-);
afterProcessAssets
SyncHook
Called after the processAssets hook had finished without error.
needAdditionalSeal
SyncBailHook
Called to determine if the compilation needs to be unsealed to include other files.
afterSeal
AsyncSeriesHook
Executed right after needAdditionalSeal.
chunkHash
SyncHook
Triggered to emit the hash for each chunk.
Callback Parameters: chunkchunkHash
moduleAsset
SyncHook
Called when an asset from a module was added to the compilation.
Callback Parameters: modulefilename
chunkAsset
SyncHook
Triggered when an asset from a chunk was added to the compilation.
Callback Parameters: chunkfilename
assetPath
SyncWaterfallHook
Called to determine the path of an asset.
Callback Parameters: pathoptions
needAdditionalPass
SyncBailHook
Called to determine if an asset needs to be processed further after being emitted.
\ No newline at end of file
diff --git a/api/compilation-object/index.html b/api/compilation-object/index.html
index aa0c774a7b24..af894f60d84d 100644
--- a/api/compilation-object/index.html
+++ b/api/compilation-object/index.html
@@ -1 +1 @@
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/api/compiler-hooks/index.html b/api/compiler-hooks/index.html
index 7e9ec763fa87..20984494f5ae 100644
--- a/api/compiler-hooks/index.html
+++ b/api/compiler-hooks/index.html
@@ -26,4 +26,4 @@
(file,{ content, source, outputPath, compilation, targetPath })=>{
console.log(content);// <Buffer 66 6f 6f 62 61 72>}
-);
done
AsyncSeriesHook
Executed when the compilation has completed. This hook is not copied to child compilers.
Callback Parameters: stats
additionalPass
AsyncSeriesHook
This hook allows you to do a one more additional pass of the build.
failed
SyncHook
Called if the compilation fails.
Callback Parameters: error
invalid
SyncHook
Executed when a watching compilation has been invalidated. This hook is not copied to child compilers.
\ No newline at end of file
diff --git a/api/contextmodulefactory-hooks/index.html b/api/contextmodulefactory-hooks/index.html
index c206574c3488..8c36512ff84e 100644
--- a/api/contextmodulefactory-hooks/index.html
+++ b/api/contextmodulefactory-hooks/index.html
@@ -1,3 +1,3 @@
\ No newline at end of file
+depending on the type of hook.
beforeResolve
AsyncSeriesWaterfallHook
Called before resolving the requested directory. The request can be ignored by returning false.
Callback Parameters: data
afterResolve
AsyncSeriesWaterfallHook
Called after the requested directory resolved.
Callback Parameters: data
contextModuleFiles
SyncWaterfallHook
Called after directory contents are read. On recursive mode, calls for each sub-directory as well. Callback parameter is an array of all file and folder names in each directory.
Callback Parameters: fileNames
alternativeRequests
AsyncSeriesWaterfallHook
Called for each file after the request is created but before filtering against regExp.
\ No newline at end of file
diff --git a/api/hot-module-replacement/index.html b/api/hot-module-replacement/index.html
index 962ec06eedf5..8f70fd74d37c 100644
--- a/api/hot-module-replacement/index.html
+++ b/api/hot-module-replacement/index.html
@@ -147,4 +147,4 @@
});
Bear in mind that when the status handler returns a Promise, the HMR system will wait for the Promise to resolve before continuing.
removeStatusHandler
Remove a registered status handler.
module.hot.removeStatusHandler(callback);// or
-import.meta.webpackHot.removeStatusHandler(callback);
\ No newline at end of file
diff --git a/api/index.html b/api/index.html
index 5f988f885245..13ce7af71068 100644
--- a/api/index.html
+++ b/api/index.html
@@ -14,4 +14,4 @@
a new version of that code with transformations applied.
The plugin interface allows users to tap directly into the compilation process.
Plugins can register handlers on lifecycle hooks that run at different points
throughout a compilation. When each hook is executed, the plugin will have full
-access to the current state of the compilation.
\ No newline at end of file
diff --git a/api/loaders/index.html b/api/loaders/index.html
index 67914dcd488d..9d389fcf1564 100644
--- a/api/loaders/index.html
+++ b/api/loaders/index.html
@@ -185,4 +185,4 @@
};
extract-style-loader/getStyles.js
module.exports=function(source){const match = source.match(STYLES_REGEXP);return match[0];
-};
Logging
Logging API is available since the release of webpack 4.37. When logging is enabled in stats configuration and/or when infrastructure logging is enabled, loaders may log messages which will be printed out in the respective logger format (stats, infrastructure).
Loaders should prefer to use this.getLogger() for logging which is a shortcut to compilation.getLogger() with loader path and processed file. This kind of logging is stored to the Stats and formatted accordingly. It can be filtered and exported by the webpack user.
Loaders may use this.getLogger('name') to get an independent logger with a child name. Loader path and processed file is still added.
Loaders may use special fallback logic for detecting logging support this.getLogger ? this.getLogger() : console to provide a fallback when an older webpack version is used which does not support getLogger method.
Logging API is available since the release of webpack 4.37. When logging is enabled in stats configuration and/or when infrastructure logging is enabled, loaders may log messages which will be printed out in the respective logger format (stats, infrastructure).
Loaders should prefer to use this.getLogger() for logging which is a shortcut to compilation.getLogger() with loader path and processed file. This kind of logging is stored to the Stats and formatted accordingly. It can be filtered and exported by the webpack user.
Loaders may use this.getLogger('name') to get an independent logger with a child name. Loader path and processed file is still added.
Loaders may use special fallback logic for detecting logging support this.getLogger ? this.getLogger() : console to provide a fallback when an older webpack version is used which does not support getLogger method.
\ No newline at end of file
diff --git a/api/module-variables/index.html b/api/module-variables/index.html
index 5e1d4ae57ec8..7538bc88b099 100644
--- a/api/module-variables/index.html
+++ b/api/module-variables/index.html
@@ -52,4 +52,4 @@
return filename +'.changed';};
__non_webpack_require__ (webpack-specific)
Generates a require function that is not parsed by webpack. Can be used to do cool stuff with a global require function if available.
__webpack_exports_info__ (webpack-specific)
In modules, __webpack_exports_info__ is available to allow exports introspection:
__webpack_exports_info__ is always true
__webpack_exports_info__.<exportName>.used is false when the export is known to be unused, true otherwise
__webpack_exports_info__.<exportName>.useInfo is
false when the export is known to be unused
true when the export is known to be used
null when the export usage could depend on runtime conditions
undefined when no info is available
__webpack_exports_info__.<exportName>.provideInfo is
false when the export is known to be not provided
true when the export is known to be provided
null when the export provision could depend on runtime conditions
undefined when no info is available
Accessing the info from nested exports is possible: i. e. __webpack_exports_info__.<exportName>.<exportName>.<exportName>.used
Check whether exports can be mangled with __webpack_exports_info__.<name>.canMangle
__webpack_is_included__ (webpack-specific)
5.16.0+
Test whether or not the given module is bundled by webpack.
if(__webpack_is_included__('./module-a.js')){// do something
-}
\ No newline at end of file
diff --git a/api/node/index.html b/api/node/index.html
index fd6be5825522..7c56b026f63e 100644
--- a/api/node/index.html
+++ b/api/node/index.html
@@ -166,4 +166,4 @@
and many other packages, uses to mysteriously hide your files but continue
serving them up to the browser!
\ No newline at end of file
diff --git a/api/normalmodulefactory-hooks/index.html b/api/normalmodulefactory-hooks/index.html
index 6e429264814f..768740b38302 100644
--- a/api/normalmodulefactory-hooks/index.html
+++ b/api/normalmodulefactory-hooks/index.html
@@ -1,3 +1,3 @@
\ No newline at end of file
+depending on the type of hook.
beforeResolve
AsyncSeriesBailHook
Called when a new dependency request is encountered. A dependency can be ignored by returning false. Otherwise, it should return undefined to proceed.
Callback Parameters: resolveData
factorize
AsyncSeriesBailHook
Called before initiating resolve. It should return undefined to proceed.
Callback Parameters: resolveData
resolve
AsyncSeriesBailHook
Called before the request is resolved. A dependency can be ignored by returning false. Returning a Module instance would finalize the process. Otherwise, it should return undefined to proceed.
Callback Parameters: resolveData
resolveForScheme
AsyncSeriesBailHook
Called before a request with scheme (URI) is resolved.
Callback Parameters: resolveData
afterResolve
AsyncSeriesBailHook
Called after the request is resolved.
Callback Parameters: resolveData
createModule
AsyncSeriesBailHook
Called before a NormalModule instance is created.
Callback Parameters: createDataresolveData
createModuleClass
HookMap<SyncBailHook>
5.81.0+
A hook that allows you to override the NormalModule class when creating modules. This hook is called after the createModule hook and before the module hook.
Hook Parameters: identifier
Callback Parameters: createDataresolveData
module
SyncWaterfallHook
Called after a NormalModule instance is created.
Callback Parameters: modulecreateDataresolveData
createParser
HookMap<SyncBailHook>
Called before a Parser instance is created. parserOptions is options in module.parser for the corresponding identifier or an empty object.
Hook Parameters: identifier
Callback Parameters: parserOptions
parser
HookMap<SyncHook>
Fired after a Parser instance is created.
Hook Parameters: identifier
Callback Parameters: parserparserOptions
Possible default identifiers:
javascript/auto
javascript/dynamic
javascript/esm
json
webassembly/sync
webassembly/async
asset
createGenerator
HookMap<SyncBailHook>
Called before a Generator instance is created. generatorOptions is options in module.parser for the corresponding identifier or an empty object.
\ No newline at end of file
diff --git a/api/parser/index.html b/api/parser/index.html
index eb941f600c35..6d114814b2e8 100644
--- a/api/parser/index.html
+++ b/api/parser/index.html
@@ -69,4 +69,4 @@
parser.hooks.new.for('MyClass').tap('MyPlugin',(expression)=>{});
expression
SyncBailHook
Called when parsing an expression.
Hook Parameters: identifier
Callback Parameters: expression
const a =this;
-parser.hooks.expression.for('this').tap('MyPlugin',(expression)=>{});
expressionConditionalOperator
SyncBailHook
Called when parsing a ConditionalExpression e.g. condition ? a : b
Callback Parameters: expression
program
SyncBailHook
Get access to the abstract syntax tree (AST) of a code fragment
\ No newline at end of file
diff --git a/api/plugins/index.html b/api/plugins/index.html
index 03d9640feee4..c92c5bb9fe12 100644
--- a/api/plugins/index.html
+++ b/api/plugins/index.html
@@ -78,4 +78,4 @@
},1000);});
The reportProgress function may be called with these arguments:
reportProgress(percentage,...args);
percentage: This argument is unused; instead, ProgressPlugin will calculate a percentage based on the current hook.
...args: Any number of strings, which will be passed to the ProgressPlugin handler to be reported to the user.
Note that only a subset of compiler and compilation hooks support the reportProgress function. See ProgressPlugin for a full list.
Logging
Logging API is available since the release of webpack 4.37. When logging is enabled in stats configuration and/or when infrastructure logging is enabled, plugins may log messages which will be printed out in the respective logger format (stats, infrastructure).
Plugins should prefer to use compilation.getLogger('PluginName') for logging. This kind of logging is stored in the Stats and formatted accordingly. It can be filtered and exported by the user.
Plugins may use the compiler.getInfrastructureLogger('PluginName') for logging. Using infrastructure logging is not stored in the Stats and therefore not formatted. It's usually logged to the console/dashboard/GUI directly. It can be filtered by the user.
Plugins may use special fallback logic for detecting logging support compilation.getLogger ? compilation.getLogger('PluginName') : console to provide a fallback for cases when an older webpack version is used which does not support getLogger method on compilation object.
Next Steps
See the compiler hooks section for a detailed listing of all the available
-compiler hooks and the parameters they make available.
\ No newline at end of file
diff --git a/api/resolvers/index.html b/api/resolvers/index.html
index 448a17207957..1c4b1cbd77db 100644
--- a/api/resolvers/index.html
+++ b/api/resolvers/index.html
@@ -15,4 +15,4 @@
with the resolve or resolveLoader options. These options allow
users to change the resolving behavior through a variety of options including
through resolve plugins.
\ No newline at end of file
diff --git a/api/stats/index.html b/api/stats/index.html
index 54828bfa4349..48da262d554a 100644
--- a/api/stats/index.html
+++ b/api/stats/index.html
@@ -167,4 +167,4 @@
],"details":"at RequireContextDependency.getWarnings (C:\\Repos\\webpack\\lib\\dependencies\\ContextDependency.js:79:5)\n at Compilation.reportDependencyErrorsAndWarnings (C:\\Repos\\webpack\\lib\\Compilation.js:1727:24)\n at C:\\Repos\\webpack\\lib\\Compilation.js:1467:10\n at _next2 (<anonymous>:16:1)\n at eval (<anonymous>:42:1)\n at C:\\Repos\\webpack\\node_modules\\neo-async\\async.js:2830:7\n at Object.each (C:\\Repos\\webpack\\node_modules\\neo-async\\async.js:2850:39)\n at C:\\Repos\\webpack\\lib\\FlagDependencyExportsPlugin.js:219:18\n at C:\\Repos\\webpack\\node_modules\\neo-async\\async.js:2830:7\n at Object.each (C:\\Repos\\webpack\\node_modules\\neo-async\\async.js:2850:39)\n at C:\\Repos\\webpack\\lib\\FlagDependencyExportsPlugin.js:40:16\n at Hook.eval [as callAsync] (<anonymous>:38:1)\n at Hook.CALL_ASYNC_DELEGATE [as _callAsync] (C:\\Repos\\tapable\\lib\\Hook.js:18:14)\n at Compilation.finish (C:\\Repos\\webpack\\lib\\Compilation.js:1462:28)\n at C:\\Repos\\webpack\\lib\\Compiler.js:909:18\n at processTicksAndRejections (internal/process/task_queues.js:75:11)\n","stack":"ModuleDependencyWarning: Critical dependency: Contexts can't use RegExps with the 'g' or 'y' flags.\n at Compilation.reportDependencyErrorsAndWarnings (C:\\Repos\\webpack\\lib\\Compilation.js:1732:23)\n at C:\\Repos\\webpack\\lib\\Compilation.js:1467:10\n at _next2 (<anonymous>:16:1)\n at eval (<anonymous>:42:1)\n at C:\\Repos\\webpack\\node_modules\\neo-async\\async.js:2830:7\n at Object.each (C:\\Repos\\webpack\\node_modules\\neo-async\\async.js:2850:39)\n at C:\\Repos\\webpack\\lib\\FlagDependencyExportsPlugin.js:219:18\n at C:\\Repos\\webpack\\node_modules\\neo-async\\async.js:2830:7\n at Object.each (C:\\Repos\\webpack\\node_modules\\neo-async\\async.js:2850:39)\n at C:\\Repos\\webpack\\lib\\FlagDependencyExportsPlugin.js:40:16\n at Hook.eval [as callAsync] (<anonymous>:38:1)\n at Hook.CALL_ASYNC_DELEGATE [as _callAsync] (C:\\Repos\\tapable\\lib\\Hook.js:18:14)\n at Compilation.finish (C:\\Repos\\webpack\\lib\\Compilation.js:1462:28)\n at C:\\Repos\\webpack\\lib\\Compiler.js:909:18\n at processTicksAndRejections (internal/process/task_queues.js:75:11)\n"
-}
\ No newline at end of file
diff --git a/app-shell/index.html b/app-shell/index.html
index d630c296ecc6..bec9bca85a3d 100644
--- a/app-shell/index.html
+++ b/app-shell/index.html
@@ -1 +1 @@
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/awesome-webpack/index.html b/awesome-webpack/index.html
index e2b8528affd7..04be7e0fff66 100644
--- a/awesome-webpack/index.html
+++ b/awesome-webpack/index.html
@@ -1,3 +1,3 @@
\ No newline at end of file
+. -- Maintainer: Ricardo Gobbo de Souza
Exclude Assets Webpack Plugin: A plugin to exclude assets from webpack output based on a path RegExp pattern. -- Maintainer: Klayton Faria
Webpack Shell Plugin Next: A plugin allows you to run any shell commands before or after webpack builds. -- Maintainer: Kuzmin Pavel
Gettext Webpack Plugin: Embed localization into your bundle using gettext. -- Maintainer: Juan Luis Paz
webpack-typescript-directory-compile-plugin Configure an source directory of typescript files and an output directory for JavaScript files. Each typescript file in the source directory and any newly added files will be compiled to individual JavaScript files. -- Maintainer: Stephen Sigwart
CycloneDX Webpack Plugin: Create CycloneDX Software Bill of Materials (SBOM) from webpack bundles at compile time. -- Maintainer: OWASP CycloneDX Team
Transpile Webpack Plugin: Transpiles input files into output files individually without bundling together. -- Maintainer: Chungen Li
Webpack Tools
Webpack Dev Middleware: Middleware which arguments a live bundle. -- Maintainer: Webpack Team
Webpack Dev Server: Serves a webpack app. Updates the browser on changes. -- Maintainer: Webpack Team
Webpack Merge - Merge designed for Webpack. -- Maintainer: Juho Vepsäläinen
NPM Install Webpack - Automatically install & save deps with Webpack. -- Maintainer: Eric Clemmons
Webpack Validator - Validates your webpack config with Joi. -- Maintainer: js-dxtools Team
Webpack Config Utils - Util. to make your webpack config easier to read. -- Maintainer: Kent C. Dodds
Read - A highly scalable react boilerplate from logustra
@route-resource-preload/webpack-plugin - Focus on improving the first screen loading speed of applications and providing the best user experience, inspiration comes from the preloading of NextJS from Devin Deng.
Vue
Vuad - A highly scalable vue boilerplate from logustra
\ No newline at end of file
diff --git a/blog/2020-10-10-webpack-5-release/index.html b/blog/2020-10-10-webpack-5-release/index.html
index edafccfebd53..97aa0f4f13bb 100644
--- a/blog/2020-10-10-webpack-5-release/index.html
+++ b/blog/2020-10-10-webpack-5-release/index.html
@@ -168,4 +168,4 @@
[path.resolve(__dirname,'....')]:false,},},
-};
Minor Changes
Compiler.name: When generating a compiler name with absolute paths, make sure to separate them with | or ! on both parts of the name.
Using space as a separator is now deprecated. (Paths could contain spaces)
Hint: | is replaced with space in Stats string output.
SystemPlugin is now disabled by default.
MIGRATION: Avoid using it as the spec has been removed. You can re-enable it with Rule.parser.system: true
ModuleConcatenationPlugin: concatenation is no longer prevented by DependencyVariables as they have been removed
This means it can now concatenate in cases of module, global, process or the ProvidePlugin
Stats.presetToOptions removed
MIGRATION: Use compilation.createStatsOptions instead
SingleEntryPlugin and SingleEntryDependency removed
MIGRATION: use EntryPlugin and EntryDependency
Chunks can now have multiple entry modules
ExtendedAPIPlugin removed
MIGRATION: No longer needed, __webpack_hash__ and __webpack_chunkname__ can always be used and runtime code is injected where needed.
ProgressPlugin no longer uses tapable context for reportProgress
MIGRATION: Use ProgressPlugin.getReporter(compiler) instead
ProvidePlugin is now re-enabled for .mjs files
Stats json errors and warnings no longer contain strings but objects with information splitted into properties.
MIGRATION: Access the information on the properties. i. e. message
Compilation.hooks.normalModuleLoader is deprecated
MIGRATION: Use NormalModule.getCompilationHooks(compilation).loader instead
Changed hooks in NormalModuleFactory from waterfall to bailing, changed and renamed hooks that return waterfall functions
Removed compilationParams.compilationDependencies
Plugins can add dependencies to the compilation by adding to compilation.file/context/missingDependencies
Compat layer will delegate compilationDependencies.add to fileDependencies.add
stats.assetsByChunkName[x] is now always an array
__webpack_get_script_filename__ function added to get the filename of a script file
"sideEffects" in package.json will be handled by glob-to-regex instead of micromatch
This may have changed semantics in edge-cases
checkContext was removed from IgnorePlugin
New __webpack_exports_info__ API allows export usage introspection
SourceMapDevToolPlugin applies to non-chunk assets too now
EnvironmentPlugin shows an error now when referenced env variable is missing and has no fallback
Remove serve property from schema
Other Minor Changes
removed builtin directory and replaced builtins with runtime modules
Removed deprecated features
BannerPlugin now only support one argument that can be an object, string or function
removed CachePlugin
Chunk.entryModule is deprecated, use ChunkGraph instead
Chunk.hasEntryModule is deprecated
Chunk.addModule is deprecated
Chunk.removeModule is deprecated
Chunk.getNumberOfModules is deprecated
Chunk.modulesIterable is deprecated
Chunk.compareTo is deprecated
Chunk.containsModule is deprecated
Chunk.getModules is deprecated
Chunk.remove is deprecated
Chunk.moveModule is deprecated
Chunk.integrate is deprecated
Chunk.canBeIntegrated is deprecated
Chunk.isEmpty is deprecated
Chunk.modulesSize is deprecated
Chunk.size is deprecated
Chunk.integratedSize is deprecated
Chunk.getChunkModuleMaps is deprecated
Chunk.hasModuleInGraph is deprecated
Chunk.updateHash signature changed
Chunk.getChildIdsByOrders signature changed (TODO: consider moving to ChunkGraph)
Chunk.getChildIdsByOrdersMap signature changed (TODO: consider moving to ChunkGraph)
Chunk.getChunkModuleMaps removed
Chunk.setModules removed
deprecated Chunk methods removed
ChunkGraph added
ChunkGroup.setParents removed
ChunkGroup.containsModule removed
Compilation.cache was removed in favor of Compilation.getCache()
ChunkGroup.remove no longer disconnected the group from block
ChunkGroup.compareTo signature changed
ChunkGroup.getChildrenByOrders signature changed
ChunkGroup index and index renamed to pre/post order index
\ No newline at end of file
diff --git a/blog/2020-12-08-roadmap-2021/index.html b/blog/2020-12-08-roadmap-2021/index.html
index 695ab36726bf..f83299b8d60e 100644
--- a/blog/2020-12-08-roadmap-2021/index.html
+++ b/blog/2020-12-08-roadmap-2021/index.html
@@ -62,4 +62,4 @@
Once the proposal reaches Stage 4 we can enable it by default.
This might also lead to a wider adoption of WebAssembly in the ecosystem.
I think we might see more in this field in 2021.
Disclaimer
This list is not set in stone.
The web ecosystem changes so fast that we probably end up implementing totally different things, that we might not even aware of at this time.
-We do not even know how much time we can invest in webpack, considering our current sponsoring situation.
\ No newline at end of file
diff --git a/blog/index.html b/blog/index.html
index 05c458037e5d..e04fb714b4d9 100644
--- a/blog/index.html
+++ b/blog/index.html
@@ -1 +1 @@
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/branding/index.html b/branding/index.html
index 2c95f1e6688d..62f55fd75326 100644
--- a/branding/index.html
+++ b/branding/index.html
@@ -1,3 +1,3 @@
\ No newline at end of file
diff --git a/comparison/index.html b/comparison/index.html
index bfb113c5672e..7113e9b75ce5 100644
--- a/comparison/index.html
+++ b/comparison/index.html
@@ -1 +1 @@
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/concepts/configuration/index.html b/concepts/configuration/index.html
index eb2ce116d80f..a0547dffec8b 100644
--- a/concepts/configuration/index.html
+++ b/concepts/configuration/index.html
@@ -7,4 +7,4 @@
path: path.resolve(__dirname,'dist'),
filename:'foo.bundle.js',},
-};
\ No newline at end of file
diff --git a/concepts/dependency-graph/index.html b/concepts/dependency-graph/index.html
index 0f3a54c75fba..06abcee9d633 100644
--- a/concepts/dependency-graph/index.html
+++ b/concepts/dependency-graph/index.html
@@ -1,2 +1,2 @@
\ No newline at end of file
+Starting from these entry points, webpack recursively builds a dependency graph that includes every module your application needs, then bundles all of those modules into a small number of bundles - often, only one - to be loaded by the browser.
\ No newline at end of file
diff --git a/concepts/entry-points/index.html b/concepts/entry-points/index.html
index 027418caa2cf..89b798ac0fc4 100644
--- a/concepts/entry-points/index.html
+++ b/concepts/entry-points/index.html
@@ -69,4 +69,4 @@
pageTwo:'./src/pageTwo/index.js',
pageThree:'./src/pageThree/index.js',},
-};
What does this do? We are telling webpack that we would like 3 separate dependency graphs (like the above example).
Why? In a multi-page application, the server is going to fetch a new HTML document for you. The page reloads this new document and assets are redownloaded. However, this gives us the unique opportunity to do things like using optimization.splitChunks to create bundles of shared application code between each page. Multi-page applications that reuse a lot of code/modules between entry points can greatly benefit from these techniques, as the number of entry points increases.
What does this do? We are telling webpack that we would like 3 separate dependency graphs (like the above example).
Why? In a multi-page application, the server is going to fetch a new HTML document for you. The page reloads this new document and assets are redownloaded. However, this gives us the unique opportunity to do things like using optimization.splitChunks to create bundles of shared application code between each page. Multi-page applications that reuse a lot of code/modules between entry points can greatly benefit from these techniques, as the number of entry points increases.
\ No newline at end of file
diff --git a/concepts/hot-module-replacement/index.html b/concepts/hot-module-replacement/index.html
index a9805e40b270..fe05cf1c3a53 100644
--- a/concepts/hot-module-replacement/index.html
+++ b/concepts/hot-module-replacement/index.html
@@ -1 +1 @@
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/concepts/index.html b/concepts/index.html
index 071fc865ba75..4b06d62f1cdb 100644
--- a/concepts/index.html
+++ b/concepts/index.html
@@ -27,4 +27,4 @@
plugins:[newHtmlWebpackPlugin({ template:'./src/index.html'})],};
In the example above, the html-webpack-plugin generates an HTML file for your application and automatically injects all your generated bundles into this file.
Using plugins in your webpack configuration is straightforward. However, there are many use cases that are worth further exploration. Learn more about them here.
Mode
By setting the mode parameter to either development, production or none, you can enable webpack's built-in optimizations that correspond to each environment. The default value is production.
module.exports ={
mode:'production',
-};
Learn more about the mode configuration here and what optimizations take place on each value.
Browser Compatibility
Webpack supports all browsers that are ES5-compliant (IE8 and below are not supported). Webpack needs Promise for import() and require.ensure(). If you want to support older browsers, you will need to load a polyfill before using these expressions.
Learn more about the mode configuration here and what optimizations take place on each value.
Browser Compatibility
Webpack supports all browsers that are ES5-compliant (IE8 and below are not supported). Webpack needs Promise for import() and require.ensure(). If you want to support older browsers, you will need to load a polyfill before using these expressions.
\ No newline at end of file
diff --git a/concepts/loaders/index.html b/concepts/loaders/index.html
index 9657fd091a40..61fd431584ae 100644
--- a/concepts/loaders/index.html
+++ b/concepts/loaders/index.html
@@ -24,4 +24,4 @@
},],},
-};
Inline
It's possible to specify loaders in an import statement, or any equivalent "importing" method. Separate loaders from the resource with !. Each part is resolved relative to the current directory.
Options can be passed with a query parameter, e.g. ?key=value&foo=bar, or a JSON object, e.g. ?{"key":"value","foo":"bar"}.
Loader Features
Loaders can be chained. Each loader in the chain applies transformations to the processed resource. A chain is executed in reverse order. The first loader passes its result (resource with applied transformations) to the next one, and so forth. Finally, webpack expects JavaScript to be returned by the last loader in the chain.
Loaders can be synchronous or asynchronous.
Loaders run in Node.js and can do everything that’s possible there.
Loaders can be configured with an options object (using query parameters to set options is still supported but has been deprecated).
Normal modules can export a loader in addition to the normal main via package.json with the loader field.
Plugins can give loaders more features.
Loaders can emit additional arbitrary files.
Loaders provide a way to customize the output through their preprocessing functions. Users now have more flexibility to include fine-grained logic such as compression, packaging, language translations and more.
Resolving Loaders
Loaders follow the standard module resolution. In most cases it will be loaded from the module path (think npm install, node_modules).
A loader module is expected to export a function and be written in Node.js compatible JavaScript. They are most commonly managed with npm, but you can also have custom loaders as files within your application. By convention, loaders are usually named xxx-loader (e.g. json-loader). See "Writing a Loader" for more information.
It's possible to specify loaders in an import statement, or any equivalent "importing" method. Separate loaders from the resource with !. Each part is resolved relative to the current directory.
Options can be passed with a query parameter, e.g. ?key=value&foo=bar, or a JSON object, e.g. ?{"key":"value","foo":"bar"}.
Loader Features
Loaders can be chained. Each loader in the chain applies transformations to the processed resource. A chain is executed in reverse order. The first loader passes its result (resource with applied transformations) to the next one, and so forth. Finally, webpack expects JavaScript to be returned by the last loader in the chain.
Loaders can be synchronous or asynchronous.
Loaders run in Node.js and can do everything that’s possible there.
Loaders can be configured with an options object (using query parameters to set options is still supported but has been deprecated).
Normal modules can export a loader in addition to the normal main via package.json with the loader field.
Plugins can give loaders more features.
Loaders can emit additional arbitrary files.
Loaders provide a way to customize the output through their preprocessing functions. Users now have more flexibility to include fine-grained logic such as compression, packaging, language translations and more.
Resolving Loaders
Loaders follow the standard module resolution. In most cases it will be loaded from the module path (think npm install, node_modules).
A loader module is expected to export a function and be written in Node.js compatible JavaScript. They are most commonly managed with npm, but you can also have custom loaders as files within your application. By convention, loaders are usually named xxx-loader (e.g. json-loader). See "Writing a Loader" for more information.
\ No newline at end of file
diff --git a/concepts/manifest/index.html b/concepts/manifest/index.html
index 9b85bb5348b4..0cc0414a6ef0 100644
--- a/concepts/manifest/index.html
+++ b/concepts/manifest/index.html
@@ -1 +1 @@
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/concepts/module-federation/index.html b/concepts/module-federation/index.html
index daa1d626a4a6..578bcbf66388 100644
--- a/concepts/module-federation/index.html
+++ b/concepts/module-federation/index.html
@@ -116,4 +116,4 @@
+ './Button':'./src/Button'
}
});
Uncaught TypeError: fn is not a function
You are likely missing the remote container, make sure it's added.
-If you have the container loaded for the remote you are trying to consume, but still see this error, add the host container's remote container file to the HTML as well.
Collision between modules from different remotes
If you're going to load multiple modules from different remotes, it's advised to set the output.uniqueName option for your remote builds to avoid collisions between multiple webpack runtimes.
\ No newline at end of file
+If you have the container loaded for the remote you are trying to consume, but still see this error, add the host container's remote container file to the HTML as well.
Collision between modules from different remotes
If you're going to load multiple modules from different remotes, it's advised to set the output.uniqueName option for your remote builds to avoid collisions between multiple webpack runtimes.
\ No newline at end of file
diff --git a/concepts/module-resolution/index.html b/concepts/module-resolution/index.html
index 2c31ea1d8391..f66f6e2f7214 100644
--- a/concepts/module-resolution/index.html
+++ b/concepts/module-resolution/index.html
@@ -8,4 +8,4 @@
import'C:\\Users\\me\\file';
Since we already have the absolute path to the file, no further resolution is required.
Relative paths
import'../src/file1';import'./file2';
In this case, the directory of the source file where the import or require occurs is taken to be the context directory. The relative path specified in the import/require is joined to this context path to produce the absolute path to the module.
Module paths
import'module';import'module/lib/file';
Modules are searched for inside all directories specified in resolve.modules.
-You can replace the original module path by an alternate path by creating an alias for it using the resolve.alias configuration option.
If the package contains a package.json file, then fields specified in resolve.exportsFields configuration options are looked up in order, and the first such field in package.json determines the available exports from the package according to the package exports guideline.
Once the path is resolved based on the above rule, the resolver checks to see if the path points to a file or a directory. If the path points to a file:
If the path has a file extension, then the file is bundled straightaway.
Otherwise, the file extension is resolved using the resolve.extensions option, which tells the resolver which extensions are acceptable for resolution e.g. .js, .jsx.
If the path points to a folder, then the following steps are taken to find the right file with the right extension:
If the folder contains a package.json file, then fields specified in resolve.mainFields configuration option are looked up in order, and the first such field in package.json determines the file path.
If there is no package.json or if the resolve.mainFields do not return a valid path, file names specified in the resolve.mainFiles configuration option are looked for in order, to see if a matching filename exists in the imported/required directory.
The file extension is then resolved in a similar way using the resolve.extensions option.
Webpack provides reasonable defaults for these options depending on your build target.
Resolving Loaders
This follows the same rules as those specified for file resolution. But the resolveLoader configuration option can be used to have separate resolution rules for loaders.
Caching
Every filesystem access is cached so that multiple parallel or serial requests to the same file occur faster. In watch mode, only modified files are evicted from the cache. If watch mode is off, then the cache gets purged before every compilation.
See Resolve API to learn more about the configuration options mentioned above.
\ No newline at end of file
+You can replace the original module path by an alternate path by creating an alias for it using the resolve.alias configuration option.
If the package contains a package.json file, then fields specified in resolve.exportsFields configuration options are looked up in order, and the first such field in package.json determines the available exports from the package according to the package exports guideline.
Once the path is resolved based on the above rule, the resolver checks to see if the path points to a file or a directory. If the path points to a file:
If the path has a file extension, then the file is bundled straightaway.
Otherwise, the file extension is resolved using the resolve.extensions option, which tells the resolver which extensions are acceptable for resolution e.g. .js, .jsx.
If the path points to a folder, then the following steps are taken to find the right file with the right extension:
If the folder contains a package.json file, then fields specified in resolve.mainFields configuration option are looked up in order, and the first such field in package.json determines the file path.
If there is no package.json or if the resolve.mainFields do not return a valid path, file names specified in the resolve.mainFiles configuration option are looked for in order, to see if a matching filename exists in the imported/required directory.
The file extension is then resolved in a similar way using the resolve.extensions option.
Webpack provides reasonable defaults for these options depending on your build target.
Resolving Loaders
This follows the same rules as those specified for file resolution. But the resolveLoader configuration option can be used to have separate resolution rules for loaders.
Caching
Every filesystem access is cached so that multiple parallel or serial requests to the same file occur faster. In watch mode, only modified files are evicted from the cache. If watch mode is off, then the cache gets purged before every compilation.
See Resolve API to learn more about the configuration options mentioned above.
\ No newline at end of file
diff --git a/concepts/modules/index.html b/concepts/modules/index.html
index f8be232eded6..5f6bcb61e9f2 100644
--- a/concepts/modules/index.html
+++ b/concepts/modules/index.html
@@ -3,4 +3,4 @@
On the web, however, support for modules has been slow to arrive.
Multiple tools exist that support modular JavaScript on the web, with a variety of benefits and limitations.
Webpack builds on lessons learned from these systems and applies the concept of modules to any file in your project.
What is a webpack Module
In contrast to Node.js modules, webpack modules can express their dependencies in a variety of ways. A few examples are:
In addition to that webpack supports modules written in a variety of languages and preprocessors via loaders. Loaders describe to webpack how to process non-native modules and include these dependencies into your bundles.
-The webpack community has built loaders for a wide variety of popular languages and language processors, including:
And many others! Overall, webpack provides a powerful and rich API for customization that allows one to use webpack for any stack, while staying non-opinionated about your development, testing, and production workflows.
And many others! Overall, webpack provides a powerful and rich API for customization that allows one to use webpack for any stack, while staying non-opinionated about your development, testing, and production workflows.
\ No newline at end of file
diff --git a/concepts/output/index.html b/concepts/output/index.html
index 185c88524d5f..c9e2fc903b65 100644
--- a/concepts/output/index.html
+++ b/concepts/output/index.html
@@ -21,4 +21,4 @@
},};
In cases where the eventual publicPath of output files isn't known at compile time, it can be left blank and set dynamically at runtime via the __webpack_public_path__ variable in the entry point file:
__webpack_public_path__ = myRuntimePublicPath;
-// rest of your application entry
\ No newline at end of file
diff --git a/concepts/targets/index.html b/concepts/targets/index.html
index a74ade8d9788..59985c6b15e1 100644
--- a/concepts/targets/index.html
+++ b/concepts/targets/index.html
@@ -19,4 +19,4 @@
//…};
-module.exports =[serverConfig, clientConfig];
The example above will create a lib.js and lib.node.js file in your dist folder.
Resources
As seen from the options above, there are multiple deployment targets that you can choose from. Below is a list of examples and resources that you can refer to.
compare-webpack-target-bundles: A great resource for testing and viewing different webpack targets. Also great for bug reporting.
\ No newline at end of file
+module.exports =[serverConfig, clientConfig];
The example above will create a lib.js and lib.node.js file in your dist folder.
Resources
As seen from the options above, there are multiple deployment targets that you can choose from. Below is a list of examples and resources that you can refer to.
compare-webpack-target-bundles: A great resource for testing and viewing different webpack targets. Also great for bug reporting.
\ No newline at end of file
diff --git a/concepts/why-webpack/index.html b/concepts/why-webpack/index.html
index 31de1bb8d86c..d83a24bfd14d 100644
--- a/concepts/why-webpack/index.html
+++ b/concepts/why-webpack/index.html
@@ -1 +1 @@
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/configuration/cache/index.html b/configuration/cache/index.html
index 54226b6f1ff7..461c85e8db35 100644
--- a/configuration/cache/index.html
+++ b/configuration/cache/index.html
@@ -145,4 +145,4 @@
key: ${{ GITHUB_REF_NAME }}-webpack-build
# fallback to use "main" branch cacherestore-keys:|
- main-webpack-build
\ No newline at end of file
diff --git a/configuration/configuration-languages/index.html b/configuration/configuration-languages/index.html
index e8d2631fd590..6d899ff4f524 100644
--- a/configuration/configuration-languages/index.html
+++ b/configuration/configuration-languages/index.html
@@ -82,4 +82,4 @@
<CustomPlugin foo="bar"/></plugins></webpack>
-);
\ No newline at end of file
diff --git a/configuration/configuration-types/index.html b/configuration/configuration-types/index.html
index a4588ab5827f..d49358256051 100644
--- a/configuration/configuration-types/index.html
+++ b/configuration/configuration-types/index.html
@@ -58,4 +58,4 @@
//config-2},];
-module.exports.parallelism =1;
\ No newline at end of file
diff --git a/configuration/devtool/index.html b/configuration/devtool/index.html
index 10ac6d29d711..74230ecf10ef 100644
--- a/configuration/devtool/index.html
+++ b/configuration/devtool/index.html
@@ -1 +1 @@
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/configuration/entry-context/index.html b/configuration/entry-context/index.html
index 6a7b67ce19f4..27e8329b92c6 100644
--- a/configuration/entry-context/index.html
+++ b/configuration/entry-context/index.html
@@ -69,4 +69,4 @@
entry(){returnfetchPathsFromSomeExternalSource();// returns a promise that will be resolved with something like ['src/main-layout.js', 'src/admin-layout.js']},
-};
When combining with the output.library option: If an array is passed only the last item is exported.
\ No newline at end of file
diff --git a/configuration/experiments/index.html b/configuration/experiments/index.html
index 2903b5a1bee6..9177601f03b7 100644
--- a/configuration/experiments/index.html
+++ b/configuration/experiments/index.html
@@ -116,4 +116,4 @@
experiments:{
topLevelAwait:true,},
-};
\ No newline at end of file
diff --git a/configuration/externals/index.html b/configuration/externals/index.html
index 9b2de0e85f6e..581650b3d76e 100644
--- a/configuration/externals/index.html
+++ b/configuration/externals/index.html
@@ -260,4 +260,4 @@
externalsPresets:{
node:true,},
-};
\ No newline at end of file
diff --git a/configuration/index.html b/configuration/index.html
index c294fbdc2af3..05766e70e4d7 100644
--- a/configuration/index.html
+++ b/configuration/index.html
@@ -30,4 +30,4 @@
+ prettier 2.7.1
+ style-loader 3.3.1
+ webpack-dev-server 4.11.1
-[webpack-cli] Project has been initialised with webpack!
\ No newline at end of file
diff --git a/configuration/mode/index.html b/configuration/mode/index.html
index 54f4ab98d66b..334b6f2c5624 100644
--- a/configuration/mode/index.html
+++ b/configuration/mode/index.html
@@ -24,4 +24,4 @@
}return config;
-};
\ No newline at end of file
diff --git a/configuration/module/index.html b/configuration/module/index.html
index 7397f1e135d4..039531df15c0 100644
--- a/configuration/module/index.html
+++ b/configuration/module/index.html
@@ -621,4 +621,4 @@
wrappedContextRegExp:/.*/,
strictExportPresence:false,},
-};
A few use cases:
Warn for dynamic dependencies: wrappedContextCritical: true.
require(expr) should include the whole directory: exprContextRegExp: /^\.\//
require('./templates/' + expr) should not include subdirectories by default: wrappedContextRecursive: false
strictExportPresence makes missing exports an error instead of warning
Set the inner regular expression for partial dynamic dependencies : wrappedContextRegExp: /\\.\\*/
\ No newline at end of file
diff --git a/configuration/node/index.html b/configuration/node/index.html
index 1fa6dc73f0a5..3a193f541cde 100644
--- a/configuration/node/index.html
+++ b/configuration/node/index.html
@@ -5,4 +5,4 @@
__filename:false,
__dirname:false,},
-};
Since webpack 3.0.0, the node option may be set to false to completely turn off the NodeStuffPlugin plugin.
false: Provide nothing. Code that expects this object may crash with a ReferenceError.
'warn': Show a warning when using global.
node.__filename
boolean'mock' | 'warn-mock' | 'eval-only'
Options:
true: The filename of the input file relative to the context option.
false: Webpack won't touch your __filename code, which means you have the regular Node.js __filename behavior. The filename of the output file when run in a Node.js environment.
'mock': The fixed value '/index.js'.
'warn-mock': Use the fixed value of '/index.js' but show a warning.
'eval-only'
node.__dirname
boolean'mock' | 'warn-mock' | 'eval-only'
Options:
true: The dirname of the input file relative to the context option.
false: Webpack won't touch your __dirname code, which means you have the regular Node.js __dirname behavior. The dirname of the output file when run in a Node.js environment.
'mock': The fixed value '/'.
'warn-mock': Use the fixed value of '/' but show a warning.
false: Provide nothing. Code that expects this object may crash with a ReferenceError.
'warn': Show a warning when using global.
node.__filename
boolean'mock' | 'warn-mock' | 'eval-only'
Options:
true: The filename of the input file relative to the context option.
false: Webpack won't touch your __filename code, which means you have the regular Node.js __filename behavior. The filename of the output file when run in a Node.js environment.
'mock': The fixed value '/index.js'.
'warn-mock': Use the fixed value of '/index.js' but show a warning.
'eval-only'
node.__dirname
boolean'mock' | 'warn-mock' | 'eval-only'
Options:
true: The dirname of the input file relative to the context option.
false: Webpack won't touch your __dirname code, which means you have the regular Node.js __dirname behavior. The dirname of the output file when run in a Node.js environment.
'mock': The fixed value '/'.
'warn-mock': Use the fixed value of '/' but show a warning.
\ No newline at end of file
diff --git a/configuration/optimization/index.html b/configuration/optimization/index.html
index 0b88adb8bf2f..3cb2865e1152 100644
--- a/configuration/optimization/index.html
+++ b/configuration/optimization/index.html
@@ -187,4 +187,4 @@
optimization:{
usedExports:'global',},
-};
\ No newline at end of file
diff --git a/configuration/other-options/index.html b/configuration/other-options/index.html
index 63042745a61b..bd8f345d7d9f 100644
--- a/configuration/other-options/index.html
+++ b/configuration/other-options/index.html
@@ -128,4 +128,4 @@
/^(.+?[\\/]node_modules[\\/](?!(@azure[\\/]msal-browser))(@.+?[\\/])?.+?)[\\/]/,],},
-};
\ No newline at end of file
diff --git a/configuration/output/index.html b/configuration/output/index.html
index 3ce3853a320a..75cf981c6155 100644
--- a/configuration/output/index.html
+++ b/configuration/output/index.html
@@ -824,4 +824,4 @@
output:{
workerPublicPath:'/workerPublicPath2/',},
-};
\ No newline at end of file
diff --git a/configuration/performance/index.html b/configuration/performance/index.html
index c0545989201e..78f3fcfc3df6 100644
--- a/configuration/performance/index.html
+++ b/configuration/performance/index.html
@@ -33,4 +33,4 @@
performance:{
maxEntrypointSize:400000,},
-};
\ No newline at end of file
diff --git a/configuration/plugins/index.html b/configuration/plugins/index.html
index 3a3343b754c4..8dd10bc762ee 100644
--- a/configuration/plugins/index.html
+++ b/configuration/plugins/index.html
@@ -23,4 +23,4 @@
newDashboardPlugin(),newwebpack.HotModuleReplacementPlugin(),],
-};
\ No newline at end of file
diff --git a/configuration/resolve/index.html b/configuration/resolve/index.html
index d0ccf9ecab35..b2dd60540867 100644
--- a/configuration/resolve/index.html
+++ b/configuration/resolve/index.html
@@ -261,4 +261,4 @@
extensions:['.js','.json'],
mainFields:['loader','main'],},
-};
\ No newline at end of file
diff --git a/configuration/stats/index.html b/configuration/stats/index.html
index 3386895958e1..5690b4c247ab 100644
--- a/configuration/stats/index.html
+++ b/configuration/stats/index.html
@@ -394,4 +394,4 @@
moduleTrace:true,
errorDetails:true,},
-};
\ No newline at end of file
diff --git a/configuration/target/index.html b/configuration/target/index.html
index 9645ccab2a18..e815ae19a5fd 100644
--- a/configuration/target/index.html
+++ b/configuration/target/index.html
@@ -19,4 +19,4 @@
newwebpack.web.JsonpTemplatePlugin(options.output),newwebpack.LoaderTargetPlugin('web'),],
-};
When no information about the target or the environment features is provided, then ES2015 will be used.
\ No newline at end of file
diff --git a/configuration/watch/index.html b/configuration/watch/index.html
index 36be8b4c679a..cfa3bd424f0b 100644
--- a/configuration/watch/index.html
+++ b/configuration/watch/index.html
@@ -48,4 +48,4 @@
watchOptions:{
stdin:true,},
-};
Troubleshooting
If you are experiencing any issues, please see the following notes. There are a variety of reasons why webpack might miss a file change.
Changes Seen But Not Processed
Verify that webpack is not being notified of changes by running webpack with the --progress flag. If progress shows on save but no files are outputted, it is likely a configuration issue, not a file watching issue.
webpack --watch --progress
Not Enough Watchers
Verify that you have enough available watchers in your system. If this value is too low, the file watcher in Webpack won't recognize the changes:
cat /proc/sys/fs/inotify/max_user_watches
Arch users, add fs.inotify.max_user_watches=524288 to /etc/sysctl.d/99-sysctl.conf and then execute sysctl --system. Ubuntu users (and possibly others), execute: echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p.
macOS fsevents Bug
On macOS, folders can get corrupted in certain scenarios. See this article.
Windows Paths
Because webpack expects absolute paths for many configuration options such as __dirname + '/app/folder' the Windows \ path separator can break some functionality.
Use the correct separators. I.e. path.resolve(__dirname, 'app/folder') or path.join(__dirname, 'app', 'folder').
Vim
On some machines Vim is preconfigured with the backupcopy option set to auto. This could potentially cause problems with the system's file watching mechanism. Switching this option to yes will make sure a copy of the file is made and the original one overwritten on save.
:set backupcopy=yes
Saving in WebStorm
When using the JetBrains WebStorm IDE, you may find that saving changed files does not trigger the watcher as you might expect. Try disabling the Back up files before saving option in the settings, which determines whether files are saved to a temporary location first before the originals are overwritten: uncheck File > {Settings|Preferences} > Appearance & Behavior > System Settings > Back up files before saving. On some versions of Webstorm, this option may be called Use "safe write" (save changes to a temporary file first).
If you are experiencing any issues, please see the following notes. There are a variety of reasons why webpack might miss a file change.
Changes Seen But Not Processed
Verify that webpack is not being notified of changes by running webpack with the --progress flag. If progress shows on save but no files are outputted, it is likely a configuration issue, not a file watching issue.
webpack --watch --progress
Not Enough Watchers
Verify that you have enough available watchers in your system. If this value is too low, the file watcher in Webpack won't recognize the changes:
cat /proc/sys/fs/inotify/max_user_watches
Arch users, add fs.inotify.max_user_watches=524288 to /etc/sysctl.d/99-sysctl.conf and then execute sysctl --system. Ubuntu users (and possibly others), execute: echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p.
macOS fsevents Bug
On macOS, folders can get corrupted in certain scenarios. See this article.
Windows Paths
Because webpack expects absolute paths for many configuration options such as __dirname + '/app/folder' the Windows \ path separator can break some functionality.
Use the correct separators. I.e. path.resolve(__dirname, 'app/folder') or path.join(__dirname, 'app', 'folder').
Vim
On some machines Vim is preconfigured with the backupcopy option set to auto. This could potentially cause problems with the system's file watching mechanism. Switching this option to yes will make sure a copy of the file is made and the original one overwritten on save.
:set backupcopy=yes
Saving in WebStorm
When using the JetBrains WebStorm IDE, you may find that saving changed files does not trigger the watcher as you might expect. Try disabling the Back up files before saving option in the settings, which determines whether files are saved to a temporary location first before the originals are overwritten: uncheck File > {Settings|Preferences} > Appearance & Behavior > System Settings > Back up files before saving. On some versions of Webstorm, this option may be called Use "safe write" (save changes to a temporary file first).
\ No newline at end of file
diff --git a/contribute/debugging/index.html b/contribute/debugging/index.html
index 72101becc3b0..4e519c11e714 100644
--- a/contribute/debugging/index.html
+++ b/contribute/debugging/index.html
@@ -1,2 +1,2 @@
\ No newline at end of file
+For help see https://nodejs.org/en/docs/inspector
Now jump to chrome://inspect in the browser and you should see any active scripts you've inspected under the Remote Target header. Click the "inspect" link under each script to open a dedicated debugger or the Open dedicated DevTools for Node link for a session that will connect automatically. You can also check out the NiM extension, a handy Chrome plugin that will automatically open a DevTools tab every time you --inspect a script.
We recommend using the --inspect-brk flag which will break on the first statement of the script allowing you to go through the source to set breakpoints and start/stop the build as you please. Also, don't forget that you can still pass arguments to the script. For example, if you have multiple configuration files you could pass --config webpack.prod.js to specify the configuration you'd like to debug.
\ No newline at end of file
diff --git a/contribute/index.html b/contribute/index.html
index da2492e00f91..aea6235f0aff 100644
--- a/contribute/index.html
+++ b/contribute/index.html
@@ -1,3 +1,3 @@
\ No newline at end of file
+If Pull Request author grants write access to their fork to the webpack Documentation team we will commit directly to your branch and finish the work. In other cases, we may have to start over by ourselves or by delegating it to willing community members. This may render your Pull Request redundant and it might get closed as a part of the cleanup process.
\ No newline at end of file
diff --git a/contribute/release-process/index.html b/contribute/release-process/index.html
index 426ea660736b..c1958a263e96 100644
--- a/contribute/release-process/index.html
+++ b/contribute/release-process/index.html
@@ -1,3 +1,3 @@
\ No newline at end of file
+npm version major &&git push --follow-tags &&npm publish
This will increment the package version, commits the changes, cuts a local tag, push to github & publish the npm package.
After that go to the github releases page and write a Changelog for the new tag.
\ No newline at end of file
diff --git a/contribute/writers-guide/index.html b/contribute/writers-guide/index.html
index cc64627878c9..a86010e616c0 100644
--- a/contribute/writers-guide/index.html
+++ b/contribute/writers-guide/index.html
@@ -14,4 +14,4 @@
foo();
Quotation
Use single quotes in code snippets and project files (.jsx, .scss etc):
- import webpack from "webpack";
+ import webpack from 'webpack';
And in inline backticks:
correct
Set value to 'index.md'...
incorrect
Set value to "index.md"...
Lists
Boo
Foo
Zoo
Lists should be ordered alphabetically.
Tables
Parameter
Explanation
Input Type
Default Value
--debug
Switch loaders to debug mode
boolean
false
--devtool
Define source map type for the bundled resources
string
-
--progress
Print compilation progress in percentage
boolean
false
Tables should also be ordered alphabetically.
Configuration Properties
The configuration properties should be ordered alphabetically as well:
devServer.compress
devServer.hot
devServer.static
Quotes
Blockquote
Syntax: >
This is a blockquote.
Tip
Syntax: T>
Syntax: W>
Syntax: ?>
Assumptions and simplicity
Do not make assumptions when writing the documentation.
- You might already know how to optimize bundle for production...
+ As we've learned in [production guide](/guides/production/)...
Please do not assume things are simple. Avoid words like 'just', 'simply'.
- Simply run command...
-+ Run the `command-name` command...
Configuration defaults and types
Always provide types and defaults to all of the documentation options in order to keep the documentation accessible and well-written. We are adding types and defaults after entitling the documented option:
configuration.example.option
string = 'none'
Where = 'none' means that the default value is 'none' for the given option.
Where : 'none' | 'development' | 'production' enumerates the possible type values, in this case, three strings are acceptable: 'none', 'development', and 'production'.
Use space between types to list all available types for the given option:
If multiple types are allowed in array, use comma:
string[string, RegExp, function(arg) => string]
To mark a function, also list arguments when they are available:
function (compilation, module, path) => boolean
Where (compilation, module, path) lists the arguments that the provided function will receive and => boolean means that the return value of the function must be a boolean.
To mark a Plugin as an available option value type, use the camel case title of the Plugin:
TerserPlugin[TerserPlugin]
Which means that the option expects one or few TerserPlugin instances.
This allows us to display the defaults, enumeration and other information.
If the object's key is dynamic, user-defined, use <key> to describe it:
object = { <key> string }
Options shortlists and their typing
Sometimes, we want to describe certain properties of objects and functions in lists. When applicable add typing directly to the list where properties are enlisted:
madeUp (boolean = true): short description
shortText (string = 'i am text'): another short description
\ No newline at end of file
++ Run the `command-name` command...
Configuration defaults and types
Always provide types and defaults to all of the documentation options in order to keep the documentation accessible and well-written. We are adding types and defaults after entitling the documented option:
configuration.example.option
string = 'none'
Where = 'none' means that the default value is 'none' for the given option.
Where : 'none' | 'development' | 'production' enumerates the possible type values, in this case, three strings are acceptable: 'none', 'development', and 'production'.
Use space between types to list all available types for the given option:
If multiple types are allowed in array, use comma:
string[string, RegExp, function(arg) => string]
To mark a function, also list arguments when they are available:
function (compilation, module, path) => boolean
Where (compilation, module, path) lists the arguments that the provided function will receive and => boolean means that the return value of the function must be a boolean.
To mark a Plugin as an available option value type, use the camel case title of the Plugin:
TerserPlugin[TerserPlugin]
Which means that the option expects one or few TerserPlugin instances.
This allows us to display the defaults, enumeration and other information.
If the object's key is dynamic, user-defined, use <key> to describe it:
object = { <key> string }
Options shortlists and their typing
Sometimes, we want to describe certain properties of objects and functions in lists. When applicable add typing directly to the list where properties are enlisted:
madeUp (boolean = true): short description
shortText (string = 'i am text'): another short description
\ No newline at end of file
diff --git a/contribute/writing-a-loader/index.html b/contribute/writing-a-loader/index.html
index eeaf7014f65a..549b17b0cd5d 100644
--- a/contribute/writing-a-loader/index.html
+++ b/contribute/writing-a-loader/index.html
@@ -168,4 +168,4 @@
Tests: 1 passed, 1 total
Snapshots: 0 total
Time: 1.853s, estimated 2s
-Ran all test suites.
It worked! At this point you should be ready to start developing, testing, and deploying your own loaders. We hope that you'll share your creations with the rest of the community!
It worked! At this point you should be ready to start developing, testing, and deploying your own loaders. We hope that you'll share your creations with the rest of the community!
\ No newline at end of file
diff --git a/contribute/writing-a-plugin/index.html b/contribute/writing-a-plugin/index.html
index cb720ca7bcc4..f289eaf67ef9 100644
--- a/contribute/writing-a-plugin/index.html
+++ b/contribute/writing-a-plugin/index.html
@@ -193,4 +193,4 @@
};
It represents that the only hook supported is shouldEmit which is a hook of SyncBailHook type and the only parameter which will be passed to any plugin that taps into shouldEmit hook is compilation.
Various types of hooks supported are :
Synchronous Hooks
SyncHook
Defined as new SyncHook([params])
Tapped into using tap method.
Called using call(...params) method.
Bail Hooks
Defined using SyncBailHook[params]
Tapped into using tap method.
Called using call(...params) method.
In these types of hooks, each of the plugin callbacks will be invoked one after the other with the specific args. If any value is returned except undefined by any plugin, then that value is returned by hook and no further plugin callback is invoked. Many useful events like optimizeChunks, optimizeChunkModules are SyncBailHooks.
Waterfall Hooks
Defined using SyncWaterfallHook[params]
Tapped into using tap method.
Called using call(...params) method
Here each of the plugins is called one after the other with the arguments from the return value of the previous plugin. The plugin must take the order of its execution into account.
It must accept arguments from the previous plugin that was executed. The value for the first plugin is init. Hence at least 1 param must be supplied for waterfall hooks. This pattern is used in the Tapable instances which are related to the webpack templates like ModuleTemplate, ChunkTemplate etc.
Asynchronous Hooks
Async Series Hook
Defined using AsyncSeriesHook[params]
Tapped into using tap/tapAsync/tapPromise method.
Called using callAsync(...params) method
The plugin handler functions are called with all arguments and a callback function with the signature (err?: Error) -> void. The handler functions are called in order of registration. callback is called after all the handlers are called.
This is also a commonly used pattern for events like emit, run.
Async waterfall The plugins will be applied asynchronously in the waterfall manner.
Defined using AsyncWaterfallHook[params]
Tapped into using tap/tapAsync/tapPromise method.
Called using callAsync(...params) method
The plugin handler functions are called with the current value and a callback function with the signature (err: Error, nextValue: any) -> void. When called nextValue is the current value for the next handler. The current value for the first handler is init. After all handlers are applied, callback is called with the last value. If any handler passes a value for err, the callback is called with this error and no more handlers are called.
-This plugin pattern is expected for events like before-resolve and after-resolve.
Async Series Bail
Defined using AsyncSeriesBailHook[params]
Tapped into using tap/tapAsync/tapPromise method.
Called using callAsync(...params) method
Async Parallel
Defined using AsyncParallelHook[params]
Tapped into using tap/tapAsync/tapPromise method.
Called using callAsync(...params) method
Configuration defaults
Webpack applies configuration defaults after plugins defaults are applied. This allows plugins to feature their own defaults and provides a way to create configuration preset plugins.
\ No newline at end of file
+This plugin pattern is expected for events like before-resolve and after-resolve.
Async Series Bail
Defined using AsyncSeriesBailHook[params]
Tapped into using tap/tapAsync/tapPromise method.
Called using callAsync(...params) method
Async Parallel
Defined using AsyncParallelHook[params]
Tapped into using tap/tapAsync/tapPromise method.
Called using callAsync(...params) method
Configuration defaults
Webpack applies configuration defaults after plugins defaults are applied. This allows plugins to feature their own defaults and provides a way to create configuration preset plugins.
\ No newline at end of file
diff --git a/glossary/index.html b/glossary/index.html
index fa739e778f53..079933a2df4e 100644
--- a/glossary/index.html
+++ b/glossary/index.html
@@ -1 +1 @@
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/guides/asset-management/index.html b/guides/asset-management/index.html
index a43d618830f0..135ca632104e 100644
--- a/guides/asset-management/index.html
+++ b/guides/asset-management/index.html
@@ -541,4 +541,4 @@
return element;
}
-document.body.appendChild(component());
\ No newline at end of file
diff --git a/guides/asset-modules/index.html b/guides/asset-modules/index.html
index 7b0a8f099203..5bd624146ad5 100644
--- a/guides/asset-modules/index.html
+++ b/guides/asset-modules/index.html
@@ -278,4 +278,4 @@
},],},
-};
\ No newline at end of file
diff --git a/guides/author-libraries/index.html b/guides/author-libraries/index.html
index 324c824fd767..3eddacbb9d15 100644
--- a/guides/author-libraries/index.html
+++ b/guides/author-libraries/index.html
@@ -139,4 +139,4 @@
...
"module":"src/index.js",
...
-}
The key main refers to the standard from package.json, and module to aproposal to allow the JavaScript ecosystem upgrade to use ES2015 modules without breaking backwards compatibility.
The key main refers to the standard from package.json, and module to aproposal to allow the JavaScript ecosystem upgrade to use ES2015 modules without breaking backwards compatibility.
\ No newline at end of file
diff --git a/guides/build-performance/index.html b/guides/build-performance/index.html
index bf79f1fe4e96..7f433b55eb5c 100644
--- a/guides/build-performance/index.html
+++ b/guides/build-performance/index.html
@@ -49,4 +49,4 @@
},},],
-};
Production
The following steps are especially useful in production.
Source Maps
Source maps are really expensive. Do you really need them?
Specific Tooling Issues
The following tools have certain problems that can degrade build performance:
Babel
Minimize the number of preset/plugins
TypeScript
Use the fork-ts-checker-webpack-plugin for typechecking in a separate process.
Configure loaders to skip typechecking.
Use the ts-loader in happyPackMode: true / transpileOnly: true.
Sass
node-sass has a bug which blocks threads from the Node.js thread pool. When using it with the thread-loader set workerParallelJobs: 2.
\ No newline at end of file
diff --git a/guides/caching/index.html b/guides/caching/index.html
index bb116ab9f407..b657ab47809f 100644
--- a/guides/caching/index.html
+++ b/guides/caching/index.html
@@ -178,4 +178,4 @@
runtime.725a1a51ede5ae0cfde0.js 1.42 KiB 2[emitted] runtime
index.html 353 bytes [emitted]
Entrypoint main = runtime.725a1a51ede5ae0cfde0.js vendors.55e79e5927a639d21a1b.js main.ad717f2466ce655fff5c.js
-...
We can see that both builds yielded 55e79e5927a639d21a1b in the vendor bundle's filename.
Conclusion
Caching can be complicated, but the benefit to application or site users makes it worth the effort. See the Further Reading section below to learn more.
We can see that both builds yielded 55e79e5927a639d21a1b in the vendor bundle's filename.
Conclusion
Caching can be complicated, but the benefit to application or site users makes it worth the effort. See the Further Reading section below to learn more.
\ No newline at end of file
diff --git a/guides/code-splitting/index.html b/guides/code-splitting/index.html
index 154ba2327cd0..b60efa2898a3 100644
--- a/guides/code-splitting/index.html
+++ b/guides/code-splitting/index.html
@@ -203,4 +203,4 @@
src="https://example.com/dist/dynamicComponent.js"asynconerror="this.remove()"
-></script>
In that case, errored script will be removed. Webpack will create its own script and any error will be processed without any timeouts.
Bundle Analysis
Once you start splitting your code, it can be useful to analyze the output to check where modules have ended up. The official analyze tool is a good place to start. There are some other community-supported options out there as well:
webpack-chart: Interactive pie chart for webpack stats.
webpack-visualizer: Visualize and analyze your bundles to see which modules are taking up space and which might be duplicates.
webpack-bundle-analyzer: A plugin and CLI utility that represents bundle content as a convenient interactive zoomable treemap.
webpack bundle optimize helper: This tool will analyze your bundle and give you actionable suggestions on what to improve to reduce your bundle size.
bundle-stats: Generate a bundle report(bundle size, assets, modules) and compare the results between different builds.
webpack-stats-viewer: A plugin with build for webpack stats. Show more information about webpack bundle detail.
Next Steps
See Lazy Loading for a more concrete example of how import() can be used in a real application and Caching to learn how to split code more effectively.
In that case, errored script will be removed. Webpack will create its own script and any error will be processed without any timeouts.
Bundle Analysis
Once you start splitting your code, it can be useful to analyze the output to check where modules have ended up. The official analyze tool is a good place to start. There are some other community-supported options out there as well:
webpack-chart: Interactive pie chart for webpack stats.
webpack-visualizer: Visualize and analyze your bundles to see which modules are taking up space and which might be duplicates.
webpack-bundle-analyzer: A plugin and CLI utility that represents bundle content as a convenient interactive zoomable treemap.
webpack bundle optimize helper: This tool will analyze your bundle and give you actionable suggestions on what to improve to reduce your bundle size.
bundle-stats: Generate a bundle report(bundle size, assets, modules) and compare the results between different builds.
webpack-stats-viewer: A plugin with build for webpack stats. Show more information about webpack bundle detail.
Next Steps
See Lazy Loading for a more concrete example of how import() can be used in a real application and Caching to learn how to split code more effectively.
\ No newline at end of file
diff --git a/guides/csp/index.html b/guides/csp/index.html
index 5461208a5b39..8aab6afd86d0 100644
--- a/guides/csp/index.html
+++ b/guides/csp/index.html
@@ -1,4 +1,4 @@
\ No newline at end of file
+https://trusted.cdn.com;
For more information on CSP and nonce attribute, please refer to Further Reading section at the bottom of this page.
Trusted Types
Webpack is also capable of using Trusted Types to load dynamically constructed scripts, to adhere to CSP require-trusted-types-for directive restrictions. See output.trustedTypes configuration option.
\ No newline at end of file
diff --git a/guides/dependency-management/index.html b/guides/dependency-management/index.html
index 2c18dfb5a5d1..3bfa1a7bc38a 100644
--- a/guides/dependency-management/index.html
+++ b/guides/dependency-management/index.html
@@ -30,4 +30,4 @@
}importAll(require.context('../components/',true,/\.js$/));
-// At build-time cache will be populated with all required modules.
id is the module id of the context module. This may be useful for module.hot.accept.
\ No newline at end of file
diff --git a/guides/development-vagrant/index.html b/guides/development-vagrant/index.html
index 882ed4657777..47c48dc21ffd 100644
--- a/guides/development-vagrant/index.html
+++ b/guides/development-vagrant/index.html
@@ -25,4 +25,4 @@
default_type text/plain;return502"Please start the webpack-dev-server first.";}
-}
The proxy_set_header lines are important, because they allow the WebSockets to work correctly.
The command to start webpack-dev-server can then be changed to this:
This makes the server only accessible on 127.0.0.1, which is fine because nginx takes care of making it available on your host PC.
Conclusion
We made the Vagrant box accessible from a static IP, and then made webpack-dev-server publicly accessible so it is reachable from a browser. We then tackled a common problem that VirtualBox doesn't send out filesystem events, causing the server to not reload on file changes.
This makes the server only accessible on 127.0.0.1, which is fine because nginx takes care of making it available on your host PC.
Conclusion
We made the Vagrant box accessible from a static IP, and then made webpack-dev-server publicly accessible so it is reachable from a browser. We then tackled a common problem that VirtualBox doesn't send out filesystem events, causing the server to not reload on file changes.
\ No newline at end of file
diff --git a/guides/development/index.html b/guides/development/index.html
index eface3a1843b..16ce3c051fff 100644
--- a/guides/development/index.html
+++ b/guides/development/index.html
@@ -220,4 +220,4 @@
<i>[webpack-dev-middleware] assets by status 1.38 MiB [cached]2 assets
<i> cached modules 530 KiB (javascript)1.9 KiB (runtime)[cached]12 modules
<i> webpack 5.4.0 compiled successfully in19 ms
-<i>[webpack-dev-middleware] Compiled successfully.
Now fire up your browser and go to http://localhost:3000. You should see your webpack app running and functioning!
Adjusting Your Text Editor
When using automatic compilation of your code, you could run into issues when saving your files. Some editors have a "safe write" feature that can potentially interfere with recompilation.
To disable this feature in some common editors, see the list below:
Sublime Text 3: Add atomic_save: 'false' to your user preferences.
JetBrains IDEs (e.g. WebStorm): Uncheck "Use safe write" in Preferences > Appearance & Behavior > System Settings.
Vim: Add :set backupcopy=yes to your settings.
Conclusion
Now that you've learned how to automatically compile your code and run a development server, you can check out the next guide, which will cover Code Splitting.
\ No newline at end of file
+<i>[webpack-dev-middleware] Compiled successfully.
Now fire up your browser and go to http://localhost:3000. You should see your webpack app running and functioning!
Adjusting Your Text Editor
When using automatic compilation of your code, you could run into issues when saving your files. Some editors have a "safe write" feature that can potentially interfere with recompilation.
To disable this feature in some common editors, see the list below:
Sublime Text 3: Add atomic_save: 'false' to your user preferences.
JetBrains IDEs (e.g. WebStorm): Uncheck "Use safe write" in Preferences > Appearance & Behavior > System Settings.
Vim: Add :set backupcopy=yes to your settings.
Conclusion
Now that you've learned how to automatically compile your code and run a development server, you can check out the next guide, which will cover Code Splitting.
\ No newline at end of file
diff --git a/guides/ecma-script-modules/index.html b/guides/ecma-script-modules/index.html
index 0dc01721ce4b..f2f4ff374b7d 100644
--- a/guides/ecma-script-modules/index.html
+++ b/guides/ecma-script-modules/index.html
@@ -33,4 +33,4 @@
Setting "type": "module" in a package.json does force all files below this package.json to be ECMAScript Modules.
Setting "type": "commonjs" will instead force them to be CommonJS Modules.
{"type":"module"
-}
In addition to that, files can set the module type by using .mjs or .cjs extension. .mjs will force them to be ESM, .cjs force them to be CommonJs.
In DataURIs using the text/javascript or application/javascript mime type will also force module type to ESM.
In addition to the module format, flagging modules as ESM also affect the resolving logic, interop logic and the available symbols in modules.
Imports in ESM are resolved more strictly. Relative requests must include a filename and file extension (e.g. *.js or *.mjs) unless you have the behaviour disabled with fullySpecified=false.
Only the "default" export can be imported from non-ESM. Named exports are not available.
CommonJs Syntax is not available: require, module, exports, __filename, __dirname.
In addition to that, files can set the module type by using .mjs or .cjs extension. .mjs will force them to be ESM, .cjs force them to be CommonJs.
In DataURIs using the text/javascript or application/javascript mime type will also force module type to ESM.
In addition to the module format, flagging modules as ESM also affect the resolving logic, interop logic and the available symbols in modules.
Imports in ESM are resolved more strictly. Relative requests must include a filename and file extension (e.g. *.js or *.mjs) unless you have the behaviour disabled with fullySpecified=false.
Only the "default" export can be imported from non-ESM. Named exports are not available.
CommonJs Syntax is not available: require, module, exports, __filename, __dirname.
\ No newline at end of file
diff --git a/guides/entry-advanced/index.html b/guides/entry-advanced/index.html
index aacdf4b6b24d..043e2a997535 100644
--- a/guides/entry-advanced/index.html
+++ b/guides/entry-advanced/index.html
@@ -29,4 +29,4 @@
filename:'[name].css',}),],
-};
Running webpack with above configuration will output into ./dist as we did not specify different output path. ./dist directory will now contain four files:
Running webpack with above configuration will output into ./dist as we did not specify different output path. ./dist directory will now contain four files:
\ No newline at end of file
diff --git a/guides/environment-variables/index.html b/guides/environment-variables/index.html
index a9b015c1d43a..194eb71a6b73 100644
--- a/guides/environment-variables/index.html
+++ b/guides/environment-variables/index.html
@@ -12,4 +12,4 @@
path: path.resolve(__dirname,'dist'),},};
-};
\ No newline at end of file
diff --git a/guides/getting-started/index.html b/guides/getting-started/index.html
index da8c9da57970..b4027ea5b5c2 100644
--- a/guides/getting-started/index.html
+++ b/guides/getting-started/index.html
@@ -141,4 +141,4 @@
|- index.html
|- /src
|- index.js
-|- /node_modules
If you want to learn more about webpack's design, you can check out the basic concepts and configuration pages. Furthermore, the API section digs into the various interfaces webpack offers.
If you want to learn more about webpack's design, you can check out the basic concepts and configuration pages. Furthermore, the API section digs into the various interfaces webpack offers.
\ No newline at end of file
diff --git a/guides/hot-module-replacement/index.html b/guides/hot-module-replacement/index.html
index efc685ec711f..2c85708e66fb 100644
--- a/guides/hot-module-replacement/index.html
+++ b/guides/hot-module-replacement/index.html
@@ -227,4 +227,4 @@
Change the style on body to background: red; and you should immediately see the page's background color change without a full refresh.
styles.css
body {
- background: blue;
+ background: red;
- }
Other Code and Frameworks
There are many other loaders and examples out in the community to make HMR interact smoothly with a variety of frameworks and libraries...
\ No newline at end of file
diff --git a/guides/index.html b/guides/index.html
index d0291be58368..befb931ef9d7 100644
--- a/guides/index.html
+++ b/guides/index.html
@@ -1 +1 @@
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/guides/installation/index.html b/guides/installation/index.html
index 2ae974197a54..4a8e29c7483c 100644
--- a/guides/installation/index.html
+++ b/guides/installation/index.html
@@ -4,4 +4,4 @@
"build":"webpack --config webpack.config.js"}
Global Installation
The following NPM installation will make webpack available globally:
npminstall --global webpack
Bleeding Edge
If you are enthusiastic about using the latest that webpack has to offer, you can install beta versions or even directly from the webpack repository using the following commands:
npminstall --save-dev webpack@next
# or a specific tag/branch
-npminstall --save-dev webpack/webpack#<tagname/branchname>
\ No newline at end of file
diff --git a/guides/integrations/index.html b/guides/integrations/index.html
index 024c96445e5d..da36b2af2824 100644
--- a/guides/integrations/index.html
+++ b/guides/integrations/index.html
@@ -40,4 +40,4 @@
},
plugins:['karma-webpack'],});
-};
For more information, please visit the repository.
\ No newline at end of file
diff --git a/guides/output-management/index.html b/guides/output-management/index.html
index 6b35c935c2bc..f3d5e78c5af5 100644
--- a/guides/output-management/index.html
+++ b/guides/output-management/index.html
@@ -104,4 +104,4 @@
path: path.resolve(__dirname, 'dist'),
+ clean: true,
},
-};
Now run an npm run build and inspect the /dist folder. If everything went well you should now only see the files generated from the build and no more old files!
The Manifest
You might be wondering how webpack and its plugins seem to "know" what files are being generated. The answer is in the manifest that webpack keeps to track how all the modules map to the output bundles. If you're interested in managing webpack's output in other ways, the manifest would be a good place to start.
The manifest data can be extracted into a json file for consumption using the WebpackManifestPlugin.
We won't go through a full example of how to use this plugin within your projects, but you can read up on the concept page and the caching guide to find out how this ties into long term caching.
Conclusion
Now that you've learned about dynamically adding bundles to your HTML, let's dive into the development guide. Or, if you want to dig into more advanced topics, we would recommend heading over to the code splitting guide.
Now run an npm run build and inspect the /dist folder. If everything went well you should now only see the files generated from the build and no more old files!
The Manifest
You might be wondering how webpack and its plugins seem to "know" what files are being generated. The answer is in the manifest that webpack keeps to track how all the modules map to the output bundles. If you're interested in managing webpack's output in other ways, the manifest would be a good place to start.
The manifest data can be extracted into a json file for consumption using the WebpackManifestPlugin.
We won't go through a full example of how to use this plugin within your projects, but you can read up on the concept page and the caching guide to find out how this ties into long term caching.
Conclusion
Now that you've learned about dynamically adding bundles to your HTML, let's dive into the development guide. Or, if you want to dig into more advanced topics, we would recommend heading over to the code splitting guide.
\ No newline at end of file
diff --git a/guides/package-exports/index.html b/guides/package-exports/index.html
index ecd764b0e1d0..c5be6c904ac5 100644
--- a/guides/package-exports/index.html
+++ b/guides/package-exports/index.html
@@ -199,4 +199,4 @@
"production":"./index-optimized.js","default":"./index-optimized.js"}
-}
Looks complex, yes. We were already able to reduce some complexity due to a assumption we can make: Only node need a CommonJs version and can detect production/development with process.env.
Guidelines
Avoid the default export. It's handled differently between tooling. Only use named exports.
Never provide different APIs or semantics for different conditions.
Write your source code as ESM and transpile to CJS via babel, typescript or similar tools.
Either use .cjs or type: "commonjs" in package.json to clearly mark source code as CommonJs. This makes it statically detectable for tools if CommonJs or ESM is used. This is important for tools that only support ESM and no CommonJs.
ESM used in packages support the following types of requests:
module requests are supported, pointing to other packages with a package.json.
relative requests are supported, pointing to other files within the package.
They must not point to files outside of the package.
data: url requests are supported.
other absolute or server-relative requests are not supported by default, but they might be supported by some tools or environments.
Looks complex, yes. We were already able to reduce some complexity due to a assumption we can make: Only node need a CommonJs version and can detect production/development with process.env.
Guidelines
Avoid the default export. It's handled differently between tooling. Only use named exports.
Never provide different APIs or semantics for different conditions.
Write your source code as ESM and transpile to CJS via babel, typescript or similar tools.
Either use .cjs or type: "commonjs" in package.json to clearly mark source code as CommonJs. This makes it statically detectable for tools if CommonJs or ESM is used. This is important for tools that only support ESM and no CommonJs.
ESM used in packages support the following types of requests:
module requests are supported, pointing to other packages with a package.json.
relative requests are supported, pointing to other files within the package.
They must not point to files outside of the package.
data: url requests are supported.
other absolute or server-relative requests are not supported by default, but they might be supported by some tools or environments.
\ No newline at end of file
diff --git a/guides/production/index.html b/guides/production/index.html
index f296380a9942..f792f626a358 100644
--- a/guides/production/index.html
+++ b/guides/production/index.html
@@ -95,4 +95,4 @@
module.exports = merge(common, {
mode: 'production',
+ devtool: 'source-map',
- });
Minimize CSS
It is crucial to minimize your CSS for production. Please see the Minimizing for Production section.
CLI Alternatives
Many of the options described above can be set as command line arguments. For example, optimization.minimize can be set with --optimization-minimize, and mode can be set with --mode. Run npx webpack --help=verbose for a full list of CLI arguments.
While these shorthand methods are useful, we recommend setting these options in a webpack configuration file for more configurability.
It is crucial to minimize your CSS for production. Please see the Minimizing for Production section.
CLI Alternatives
Many of the options described above can be set as command line arguments. For example, optimization.minimize can be set with --optimization-minimize, and mode can be set with --mode. Run npx webpack --help=verbose for a full list of CLI arguments.
While these shorthand methods are useful, we recommend setting these options in a webpack configuration file for more configurability.
\ No newline at end of file
diff --git a/guides/progressive-web-application/index.html b/guides/progressive-web-application/index.html
index 82b19f959d99..c2d032391eac 100644
--- a/guides/progressive-web-application/index.html
+++ b/guides/progressive-web-application/index.html
@@ -57,4 +57,4 @@
+ console.log('SW registration failed: ', registrationError);
+ });
+ });
-+ }
Once more npm run build to build a version of the app including the registration code. Then serve it with npm start. Navigate to http://localhost:8080 and take a look at the console. Somewhere in there you should see:
SW registered
Now to test it. Stop your server and refresh your page. If your browser supports Service Workers then you should still be looking at your application. However, it has been served up by your Service Worker and not by the server.
Conclusion
You have built an offline app using the Workbox project. You've started the journey of turning your web app into a PWA. You may now want to think about taking things further. A good resource to help you with that can be found here.
Once more npm run build to build a version of the app including the registration code. Then serve it with npm start. Navigate to http://localhost:8080 and take a look at the console. Somewhere in there you should see:
SW registered
Now to test it. Stop your server and refresh your page. If your browser supports Service Workers then you should still be looking at your application. However, it has been served up by your Service Worker and not by the server.
Conclusion
You have built an offline app using the Workbox project. You've started the journey of turning your web app into a PWA. You may now want to think about taking things further. A good resource to help you with that can be found here.
\ No newline at end of file
diff --git a/guides/public-path/index.html b/guides/public-path/index.html
index a35fb82d39b2..19a0bb9c2d9a 100644
--- a/guides/public-path/index.html
+++ b/guides/public-path/index.html
@@ -22,4 +22,4 @@
output:{
publicPath:'auto',},
-};
Note that in cases where document.currentScript is not supported, e.g., IE browser, you will have to include a polyfill like currentScript Polyfill.
\ No newline at end of file
diff --git a/guides/shimming/index.html b/guides/shimming/index.html
index b35abc4f70e1..eabb6808cb8e 100644
--- a/guides/shimming/index.html
+++ b/guides/shimming/index.html
@@ -260,4 +260,4 @@
import'core-js/modules/es7.string.pad-end';import'core-js/modules/web.timers';import'core-js/modules/web.immediate';
-import'core-js/modules/web.dom.iterable';
Node built-ins, like process, can be polyfilled right directly from your configuration file without the use of any special loaders or plugins. See the node configuration page for more information and examples.
Other Utilities
There are a few other tools that can help when dealing with legacy modules.
When there is no AMD/CommonJS version of the module and you want to include the dist, you can flag this module in noParse. This will cause webpack to include the module without parsing it or resolving require() and import statements. This practice is also used to improve the build performance.
Lastly, there are some modules that support multiple module styles; e.g. a combination of AMD, CommonJS, and legacy. In most of these cases, they first check for define and then use some quirky code to export properties. In these cases, it could help to force the CommonJS path by setting additionalCode=var%20define%20=%20false; via the imports-loader.
Node built-ins, like process, can be polyfilled right directly from your configuration file without the use of any special loaders or plugins. See the node configuration page for more information and examples.
Other Utilities
There are a few other tools that can help when dealing with legacy modules.
When there is no AMD/CommonJS version of the module and you want to include the dist, you can flag this module in noParse. This will cause webpack to include the module without parsing it or resolving require() and import statements. This practice is also used to improve the build performance.
Lastly, there are some modules that support multiple module styles; e.g. a combination of AMD, CommonJS, and legacy. In most of these cases, they first check for define and then use some quirky code to export properties. In these cases, it could help to force the CommonJS path by setting additionalCode=var%20define%20=%20false; via the imports-loader.
\ No newline at end of file
diff --git a/guides/tree-shaking/index.html b/guides/tree-shaking/index.html
index 7577ceb7c0dc..426be75bdf6c 100644
--- a/guides/tree-shaking/index.html
+++ b/guides/tree-shaking/index.html
@@ -138,4 +138,4 @@
- usedExports: true,
- }
+ mode: 'production',
-};
With that squared away, we can run another npm run build and see if anything has changed.
Notice anything different about dist/bundle.js? The whole bundle is now minified and mangled, but, if you look carefully, you won't see the square function included but will see a mangled version of the cube function (function r(e){return e*e*e}n.a=r). With minification and tree shaking, our bundle is now a few bytes smaller! While that may not seem like much in this contrived example, tree shaking can yield a significant decrease in bundle size when working on larger applications with complex dependency trees.
Conclusion
What we've learned is that in order to take advantage of tree shaking, you must...
Use ES2015 module syntax (i.e. import and export).
Ensure no compilers transform your ES2015 module syntax into CommonJS modules (this is the default behavior of the popular Babel preset @babel/preset-env - see the documentation for more details).
Add a "sideEffects" property to your project's package.json file.
Make sure you set a correct value for devtool as some of them can't be used in production mode.
You can imagine your application as a tree. The source code and libraries you actually use represent the green, living leaves of the tree. Dead code represents the brown, dead leaves of the tree that are consumed by autumn. In order to get rid of the dead leaves, you have to shake the tree, causing them to fall.
If you are interested in more ways to optimize your output, please jump to the next guide for details on building for production.
With that squared away, we can run another npm run build and see if anything has changed.
Notice anything different about dist/bundle.js? The whole bundle is now minified and mangled, but, if you look carefully, you won't see the square function included but will see a mangled version of the cube function (function r(e){return e*e*e}n.a=r). With minification and tree shaking, our bundle is now a few bytes smaller! While that may not seem like much in this contrived example, tree shaking can yield a significant decrease in bundle size when working on larger applications with complex dependency trees.
Conclusion
What we've learned is that in order to take advantage of tree shaking, you must...
Use ES2015 module syntax (i.e. import and export).
Ensure no compilers transform your ES2015 module syntax into CommonJS modules (this is the default behavior of the popular Babel preset @babel/preset-env - see the documentation for more details).
Add a "sideEffects" property to your project's package.json file.
Make sure you set a correct value for devtool as some of them can't be used in production mode.
You can imagine your application as a tree. The source code and libraries you actually use represent the green, living leaves of the tree. Dead code represents the brown, dead leaves of the tree that are consumed by autumn. In order to get rid of the dead leaves, you have to shake the tree, causing them to fall.
If you are interested in more ways to optimize your output, please jump to the next guide for details on building for production.
\ No newline at end of file
diff --git a/guides/typescript/index.html b/guides/typescript/index.html
index 77f762e57c1e..4611064b5844 100644
--- a/guides/typescript/index.html
+++ b/guides/typescript/index.html
@@ -86,4 +86,4 @@
console.log(import.meta.webpack);// without reference declared above, TypeScript will throw an error
Using Third Party Libraries
When installing third party libraries from npm, it is important to remember to install the typing definition for that library.
For example, if we want to install lodash we can run the following command to get the typings for it:
npminstall --save-dev @types/lodash
If the npm package already includes its declaration typings in the package bundle, downloading the corresponding @types package is not needed. For more information see the TypeScript changelog blog.
Importing Other Assets
To use non-code assets with TypeScript, we need to defer the type for these imports. This requires a custom.d.ts file which signifies custom definitions for TypeScript in our project. Let's set up a declaration for .svg files:
Here we declare a new module for SVGs by specifying any import that ends in .svg and defining the module's content as any. We could be more explicit about it being a url by defining the type as string. The same concept applies to other assets including CSS, SCSS, JSON and more.
Here we declare a new module for SVGs by specifying any import that ends in .svg and defining the module's content as any. We could be more explicit about it being a url by defining the type as string. The same concept applies to other assets including CSS, SCSS, JSON and more.
\ No newline at end of file
diff --git a/guides/web-workers/index.html b/guides/web-workers/index.html
index 60d8265bb3c6..286c97508f8c 100644
--- a/guides/web-workers/index.html
+++ b/guides/web-workers/index.html
@@ -15,4 +15,4 @@
});};
Node.js
Similar syntax is supported in Node.js (>= 12.17.0):
\n';function de(){return(0,d.jsxs)("div",{className:"placeholder",children:[(0,d.jsx)("p",{children:" "}),(0,d.jsx)("p",{children:" "}),(0,d.jsx)("p",{children:" "})]})}var ce=i(1975);const pe=(0,r.lazy)((()=>i.e(1360).then(i.bind(i,9759)))),ue=()=>(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)("h2",{children:"Latest Sponsors"}),(0,d.jsx)(de,{}),(0,d.jsx)("h2",{children:"Platinum Sponsors"}),(0,d.jsx)(de,{}),(0,d.jsx)("h2",{children:"Gold Sponsors"}),(0,d.jsx)(de,{}),(0,d.jsx)("h2",{children:"Silver Sponsors"}),(0,d.jsx)(de,{}),(0,d.jsx)("h2",{children:"Bronze Sponsors"}),(0,d.jsx)(de,{}),(0,d.jsx)("h2",{children:"Backers"}),(0,d.jsx)(de,{})]});var me,he=()=>{const[e,t]=(0,r.useState)(!1),[i,l]=(0,r.useState)((()=>Math.random()<.33?"monthly":"total"));return(0,r.useEffect)((()=>{b()&&t(!0)}),[]),(0,d.jsxs)("div",{className:"splash",children:[(0,d.jsx)(se,{}),(0,d.jsx)("div",{className:"splash__section splash__section--dark page__content",children:(0,d.jsx)(Y,{children:(0,d.jsx)(ae,{children:(0,d.jsx)(ce.default,{})})})}),(0,d.jsx)("div",{className:"splash__section page__content",children:(0,d.jsx)(Y,{children:(0,d.jsxs)(ae,{children:[(0,d.jsx)("h1",{id:"sponsors",children:"Support the Team"}),(0,d.jsx)("p",{children:"Through contributions, donations, and sponsorship, you allow webpack to thrive. Your donations directly support office hours, continued enhancements, and most importantly, great documentation and learning material!"}),e?(0,d.jsxs)(r.Suspense,{fallback:(0,d.jsx)(ue,{}),children:[(0,d.jsx)("p",{children:(0,d.jsxs)("label",{htmlFor:"support-type",children:[(0,d.jsx)("input",{id:"support-type",type:"checkbox",checked:"monthly"===i,onChange:e=>l(e.target.checked?"monthly":"total")}),"Show sponsors by their average monthly amount of sponsoring in the last year."]})}),(0,d.jsx)(pe,{type:i,rank:"latest"}),(0,d.jsx)(pe,{type:i,rank:"platinum"}),(0,d.jsx)(pe,{type:i,rank:"gold"}),(0,d.jsx)(pe,{type:i,rank:"silver"}),(0,d.jsx)(pe,{type:i,rank:"bronze"}),(0,d.jsx)(pe,{type:i,rank:"backer"})]}):(0,d.jsx)(ue,{})]})})})]})},ge=i.p+"ag-grid-logo.27db91190cf56daf.png",ve=i.p+"icon-square-small.9e8aff7a67a5dd20.svg",be=()=>(0,d.jsx)("div",{className:"sponsors",children:(0,d.jsxs)(w,{className:"sponsors__content",to:"https://www.ag-grid.com/?utm_source=webpack&utm_medium=banner&utm_campaign=sponsorship",children:[(0,d.jsx)("img",{src:ge,width:260,height:140,alt:"ag grid",loading:"lazy"}),(0,d.jsx)("img",{className:"sponsors__img__webpack",src:ve,alt:"webpack",width:150,height:150,loading:"lazy"}),(0,d.jsx)("div",{className:"sponsors__content-cont",children:"ag-grid is proud to partner with webpack"})]})}),fe=i(3530),xe=i.n(fe);function ke(){return ke=Object.assign?Object.assign.bind():function(e){for(var t=1;tr.createElement("svg",ke({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"},e),me||(me=r.createElement("path",{d:"m9.2 4.5 4.5 4.7c.2.2.3.5.3.8s-.1.6-.3.8l-4.5 4.7c-.5.4-1.2.4-1.7 0-.4-.5-.4-1 0-1.6l3.8-3.9-3.8-4c-.4-.4-.4-1 0-1.5.5-.4 1.2-.4 1.7 0z"})));function je(){return je=Object.assign?Object.assign.bind():function(e){for(var t=1;tr.createElement("svg",je({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"},e),ye||(ye=r.createElement("path",{d:"M10 3.3c-.6 0-1 .4-1.1 1.1v11.2c0 .3.2.6.4.8s.5.4.8.4c.6 0 1-.4 1.1-1.1V4.5c0-.3-.2-.6-.4-.8s-.5-.4-.8-.4z"})));function Ee(e,t,i){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var l=i.call(e,"string");if("object"!=typeof l)return l;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}const Ce="sidebar-item";class _e extends r.Component{constructor(){super(...arguments),Ee(this,"state",{open:this._isOpen(this.props)})}scrollTop(e){""===window.location.hash&&(e.metaKey||e.ctrlKey||window.scrollTo(0,0))}renderAnchors(e){return(0,d.jsx)("ul",{className:`${Ce}__anchors`,children:e.map((e=>(0,d.jsxs)("li",{className:`${Ce}__anchor`,title:e.title,children:[(0,d.jsx)(n.OL,{to:this._generateAnchorURL(e),children:e.title2}),e.children&&this.renderAnchors(e.children)]},this._generateAnchorURL(e))))})}render(){let{title:e,anchors:t=[]}=this.props,i=this.state.open?`${Ce}--open`:"",l=0===t.length?`${Ce}--disabled`:"";const s=t.filter((e=>e.level>1)),o=xe()(e,s);return(0,d.jsxs)("div",{className:`${Ce} ${i} ${l}`,children:[t.length>0?(0,d.jsx)(we,{width:15,height:17,fill:"#175d96",className:`${Ce}__toggle`,onClick:this._toggle.bind(this)}):(0,d.jsx)(ze,{className:`${Ce}__toggle`,width:15,height:17,fill:"#175d96"}),(0,d.jsx)(n.OL,{end:!0,className:`${Ce}__title`,to:this.props.url,onClick:this.scrollTop,children:e},this.props.url),t.length>0?this.renderAnchors(o):null]})}UNSAFE_componentWillReceiveProps(e){e.currentPage!==this.props.currentPage&&this.setState({open:this._isOpen(e)})}_isOpen(e){return RegExp(`${e.currentPage}/?$`).test(e.url)}_toggle(){this.setState({open:!this.state.open})}_generateAnchorURL(e){let{url:t}=this.props;return e.id?`${t}#${e.id}`:t}}Ee(_e,"propTypes",{title:a().string,anchors:a().array,url:a().string,currentPage:a().string});var Se=i.p+"icon-print.3c147a8b5a684f88.svg";const Ne=["api","concepts","configuration","contribute","guides","loaders","migrate","plugins"];function Pe(e){const{url:t}=e,i=function(e){let t=e.split("/");return!!Ne.includes(t[1])&&`/${t[1]}/printable/`}(t);return i?(0,d.jsxs)("div",{className:"sidebar-item sidebar-item--disabled`",children:[(0,d.jsx)(ze,{className:"sidebar-item__toggle",width:15,height:17,fill:"#175d96"}),(0,d.jsxs)("a",{className:"sidebar-item__title sidebar-link__print",href:i,rel:"nofollow noopener noreferrer",alt:"Print",title:"Print",target:"_blank",children:["Print Section",(0,d.jsx)("img",{src:Se,width:27,height:20,alt:"Printer Icon"})]})]}):null}var Me;function De(){return De=Object.assign?Object.assign.bind():function(e){for(var t=1;tr.createElement("svg",De({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"},e),Me||(Me=r.createElement("path",{d:"M4.5 7.5c.5-.4 1-.4 1.6 0l3.9 3.8 4-3.8c.4-.4 1-.4 1.5 0 .4.5.4 1.2 0 1.7l-4.7 4.5a1 1 0 0 1-1.6 0L4.5 9.2c-.4-.5-.4-1.2 0-1.7z"})));function Te(){return Te=Object.assign?Object.assign.bind():function(e){for(var t=1;tr.createElement("svg",Te({xmlns:"http://www.w3.org/2000/svg",xmlSpace:"preserve",width:40,height:40,viewBox:"0 0 50 50"},e),Ae||(Ae=r.createElement("path",{d:"M43.935 25.145c0-10.318-8.364-18.683-18.683-18.683-10.318 0-18.683 8.365-18.683 18.683h4.068c0-8.071 6.543-14.615 14.615-14.615s14.615 6.543 14.615 14.615h4.068z"},r.createElement("animateTransform",{attributeName:"transform",attributeType:"xml",dur:"0.6s",from:"0 25 25",repeatCount:"indefinite",to:"360 25 25",type:"rotate"}))));const Be=[5,4],Le=5;function Ie(e){let{className:t="",pages:i,currentPage:l}=e;const[n,s]=(0,r.useState)(Le),[o,a]=(0,r.useState)(!1);let c;return(0,r.useEffect)((()=>{if(n===Le)return;const e=window.location.href,t=new URL(e);t.hostname=`v${n}.webpack.js.org`,window.location.href=t.href}),[n]),(0,d.jsx)("nav",{className:`sidebar ${t}`,children:(0,d.jsxs)("div",{className:"sidebar__inner",children:[(0,d.jsxs)("div",{className:"relative z-0 bg-white dark:bg-gray-100 ",children:[(0,d.jsx)("select",{className:"text-gray-600 text-14 px-5 py-5 appearance-none box-border border border-gray-200 border-solid flex-col flex w-full rounded-none bg-transparent bg-none",value:n,onChange:e=>{s(+e.target.value),+e.target.value!==Le&&a(!0)},children:Be.map((e=>(0,d.jsxs)("option",{value:e,children:["webpack ",e]},e)))}),o?(0,d.jsx)(Re,{className:"absolute right-5 top-5 fill-current text-gray-300 z-[-1]",width:20,height:20}):(0,d.jsx)(Oe,{className:"absolute right-5 top-5 fill-current text-gray-300 z-[-1]",width:20,height:20})]}),(0,d.jsx)(Pe,{url:l}),i.map(((e,t)=>{let i=c!==e.group&&"-"!==e.group;return c=e.group,(0,d.jsxs)("div",{children:[i?(0,d.jsx)("h4",{className:"sidebar__group",children:c}):null,(0,d.jsx)(_e,{index:t,url:e.url,title:e.title,anchors:e.anchors,currentPage:l})]},e.url)}))]})})}Ie.propTypes={className:a().string,pages:a().array,currentPage:a().string};var Fe=i.p+"cc.185f5779f354f6e9.svg",He=i.p+"by.d2da85793ea9d7bd.svg",We=()=>(0,d.jsx)("footer",{className:"footer",children:(0,d.jsxs)(Y,{className:"footer__inner",children:[(0,d.jsxs)("section",{className:"footer__left",children:[(0,d.jsx)(w,{className:"footer__link",to:"/guides/getting-started/",children:"Get Started"}),(0,d.jsx)(w,{className:"footer__link",to:"/comparison/",children:"Comparison"}),(0,d.jsx)(w,{className:"footer__link",to:"https://privacy-policy.openjsf.org/",children:"Privacy Policy"})]}),(0,d.jsx)("section",{className:"footer__middle",children:(0,d.jsx)(w,{to:"/",className:"footer__icon",children:(0,d.jsx)("img",{src:ve,alt:"webpack icon",width:35,height:35})})}),(0,d.jsxs)("section",{className:"footer__right",children:[(0,d.jsx)(w,{className:"footer__link",to:"https://webpack.threadless.com/",children:"Swag Store"}),(0,d.jsx)(w,{className:"footer__link",to:"/awesome-webpack/",children:"Awesome webpack"}),(0,d.jsx)(w,{className:"footer__link",to:"/glossary/",children:"Glossary"}),(0,d.jsx)(w,{className:"footer__link",to:"/branding/",children:"Branding"}),(0,d.jsx)(w,{className:"footer__link",to:"https://gitter.im/webpack/webpack",children:"Gitter"}),(0,d.jsx)(w,{className:"footer__link",to:"https://github.com/webpack/webpack/releases",children:"Changelog"}),(0,d.jsxs)(w,{className:"footer__link footer__license",to:"/license",children:[(0,d.jsx)("img",{alt:"Creative Commons License",src:Fe,width:25,height:25}),(0,d.jsx)("img",{alt:"Creative Commons License",src:He,width:25,height:25})]})]})]})}),Ue=i(4760);const qe="https://github.com/webpack/webpack.js.org/edit/main/";function Ge(){return(0,d.jsx)("span",{className:"mx-5 text-black font-bold dark:text-white",children:"·"})}Je.propTypes={page:a().shape({repo:a().string})};const $e="text-gray-500 dark:text-gray-500 text-sm cursor-pointer font-sans hover:underline";function Je(e){let{page:t={}}=e;const i=t.edit||Ue.resolve(qe,t.path);return(0,d.jsxs)("div",{className:"print:hidden mt-20",children:[(0,d.jsx)("a",{className:$e,href:i,children:"Edit this page"}),(0,d.jsx)(Ge,{}),(0,d.jsx)("a",{className:$e,onClick:Ve,children:"Print this page"}),t.repo?(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(Ge,{}),(0,d.jsx)("a",{className:$e,href:t.repo,children:"Jump to repository"})]}):null]})}function Ve(e){e.preventDefault(),window.print()}var Ke=i(412),Xe=i.n(Ke),Ze=i(2807);const Ye=["bartushek","rynclark","henriquea","makuzaverite","MijaelWatts","Kolhar730","grrizzly","maxloh","varunjayaraman"];function Qe(e){let{contributor:t,inView:i}=e;return(0,d.jsx)("a",{href:`https://github.com/${t}`,children:(0,d.jsx)("img",{width:45,height:45,alt:t,title:t,className:"w-full rounded-full shadow",src:i?`https://github.com/${t}.png?size=90`:Ze})},t)}function et(e){let{contributors:t}=e;const[i,l]=(0,r.useState)(!1);return t.length?(0,d.jsx)(Xe(),{delayedCall:!0,partialVisibility:!0,intervalDelay:300,onChange:e=>{e&&l(e)},children:(0,d.jsx)("div",{children:(0,d.jsx)("div",{className:"grid gap-[10px] lg:gap-[15px] grid-cols-contributors",children:t.filter((e=>!1===Ye.includes(e))).map((e=>(0,d.jsx)(Qe,{contributor:e,inView:i},e)))})})}):(0,d.jsx)("noscript",{})}function tt(e){let{previous:t,next:i}=e;return t||i?(0,d.jsxs)("div",{className:"adjacent-links print:hidden",children:[t&&(0,d.jsxs)("div",{className:"adjacent-links__prev",children:[(0,d.jsx)("div",{children:"« Previous"}),(0,d.jsx)(w,{className:"adjacent-links__link",to:t.url,children:t.title})]}),i&&(0,d.jsxs)("div",{className:"adjacent-links__next",children:[(0,d.jsx)("div",{className:"adjacent-links__label--next",children:"Next »"}),(0,d.jsx)(w,{className:"adjacent-links__link",to:i.url,children:i.title})]})]}):null}function it(e){const{title:t,contributors:i=[],related:l=[],previous:n,next:o,...a}=e,c=e.content instanceof Promise,[p,u]=(0,r.useState)(c?re():()=>e.content.default||e.content),[m,h]=(0,r.useState)(!c);(0,r.useEffect)((()=>{e.content instanceof Promise&&e.content.then((e=>{u((()=>e.default||e)),h(!0)})).catch((()=>u("Error loading content.")))}),[e.content]);const{hash:g,pathname:v}=(0,s.TH)();(0,r.useEffect)((()=>{let e;if(m)if(g){const t=document.querySelector("#md-content");document.querySelector(g)?document.querySelector(g).scrollIntoView():(e=new MutationObserver((()=>{const e=document.querySelector(g);e&&e.scrollIntoView()})),e.observe(t,{childList:!0,attributes:!1,subtree:!1}))}else window.scrollTo(0,0);return()=>{e&&e.disconnect()}}),[m,v,g]);const b=i.length,f=m&&l&&0!==l.length,x=m&&i&&0!==b;let k;return k="function"==typeof p?p({}).props.children:(0,d.jsx)("div",{dangerouslySetInnerHTML:{__html:p}}),(0,d.jsx)("section",{className:"page",children:(0,d.jsxs)(ae,{children:[(0,d.jsx)("h1",{children:t}),a.thirdParty?(0,d.jsxs)("div",{className:"italic my-[20px]",children:[(0,d.jsx)("strong",{className:"font-bold",children:"Disclaimer:"})," ",t," is a third-party package maintained by community members, it potentially does not have the same support, security policy or license as webpack, and it is not maintained by webpack."]}):null,(0,d.jsx)("div",{id:"md-content",children:k}),f&&(0,d.jsxs)("div",{className:"print:hidden",children:[(0,d.jsx)("h2",{children:"Further Reading"}),(0,d.jsx)("ul",{children:l.map(((e,t)=>(0,d.jsx)("li",{children:(0,d.jsx)(w,{to:e.url,children:e.title})},t)))})]}),(0,d.jsx)(Je,{page:a}),(n||o)&&(0,d.jsx)(tt,{previous:n,next:o}),x&&(0,d.jsxs)("div",{"data-testid":"contributors",className:"print:hidden",children:[(0,d.jsxs)("h2",{className:"!font-sans !font-normal",children:[b," ",1===b?"Contributor":"Contributors"]}),(0,d.jsx)(et,{contributors:i})]})]})})}function lt(){return(0,d.jsxs)("div",{className:"page markdown",children:[(0,d.jsx)("h1",{children:"Page Not Found"}),(0,d.jsx)("p",{children:"Oops! The page you are looking for has been removed or relocated."}),(0,d.jsx)(n.rU,{className:"button",to:"/",children:"Go to Homepage"})]})}function nt(e){return(0,d.jsx)("span",{className:"badge",children:e.text})}et.propTypes={contributors:a().array.isRequired},Qe.propTypes={contributor:a().string.isRequired,inView:a().bool.isRequired},tt.propTypes={previous:a().shape({url:a().string,title:a().string}),next:a().shape({url:a().string,title:a().string})},it.propTypes={title:a().string,contributors:a().array,related:a().array,previous:a().object,next:a().object,content:a().oneOfType([a().shape({then:a().func.isRequired,default:a().string})])},nt.propTypes={text:a().string.isRequired};var st=i.p+"open-in-stackblitz-button.d5768454f28617a0.svg";function ot(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const{example:t="",description:i="Check out this guide live on StackBlitz."}=e,l=`https://stackblitz.com/github/webpack/webpack.js.org/tree/main/examples/${t}`;return(0,d.jsxs)("aside",{className:"preview",children:[(0,d.jsx)("h6",{className:"preview__prefix",children:"live preview"}),(0,d.jsx)("p",{children:i}),(0,d.jsx)("a",{href:l,target:"_blank",rel:"noopener noreferrer",children:(0,d.jsx)("img",{src:st,alt:"Open in StackBlitz"})})]})}function at(e){return e.href.startsWith("/")?(0,d.jsx)(n.rU,{...e,to:e.href}):(0,d.jsx)("a",{...e})}ot.propTypes={description:a().string,example:a().string},at.propTypes={href:a().string.isRequired};var rt=i(2883),dt=i.p+"favicon.a3dd58d3142f7566.ico",ct=i.p+"logo-on-white-bg.4a16a9aed80e42ee.svg",pt=i.p+"icon-pwa-512x512.934507c816afbcdb.png",ut=JSON.parse('{"path":"./src/content","name":"content","children":[{"path":"src/content/api","name":"api","children":[{"path":"src/content/api/index.mdx","name":"index.mdx","size":1888,"type":"file","extension":".mdx","url":"/api/","anchors":[{"title":"CLI","id":"cli","level":2},{"title":"Module","id":"module","level":2},{"title":"Node","id":"node","level":2},{"title":"Loaders","id":"loaders","level":2},{"title":"Plugins","id":"plugins","level":2}],"title":"Introduction","sort":-1,"contributors":["tbroadley"]},{"path":"src/content/api/cli.mdx","name":"cli.mdx","size":25994,"type":"file","extension":".mdx","url":"/api/cli/","anchors":[{"title":"Commands","id":"commands","level":2},{"title":"Build","id":"build","level":3},{"title":"Init","id":"init","level":3},{"title":"Loader","id":"loader","level":3},{"title":"Plugin","id":"plugin","level":3},{"title":"Info","id":"info","level":3},{"title":"Configtest","id":"configtest","level":3},{"title":"Serve","id":"serve","level":3},{"title":"Watch","id":"watch","level":3},{"title":"Flags","id":"flags","level":2},{"title":"Negated Flags","id":"negated-flags","level":3},{"title":"Core Flags","id":"core-flags","level":3},{"title":"Usage","id":"usage","level":2},{"title":"With configuration file","id":"with-configuration-file","level":3},{"title":"Without configuration file","id":"without-configuration-file","level":3},{"title":"Default Configurations","id":"default-configurations","level":2},{"title":"Common Options","id":"common-options","level":2},{"title":"help","id":"help","level":3},{"title":"version","id":"version","level":3},{"title":"config","id":"config","level":3},{"title":"config-name","id":"config-name","level":3},{"title":"merge","id":"merge","level":3},{"title":"extends","id":"extends","level":3},{"title":"json","id":"json","level":3},{"title":"Environment Options","id":"environment-options","level":2},{"title":"env","id":"env","level":3},{"title":"node-env","id":"node-env","level":3},{"title":"define-process-env-node-env","id":"define-process-env-node-env","level":3},{"title":"Configuration Options","id":"configuration-options","level":2},{"title":"Analyzing Bundle","id":"analyzing-bundle","level":2},{"title":"Progress","id":"progress","level":2},{"title":"Pass CLI arguments to Node.js","id":"pass-cli-arguments-to-nodejs","level":2},{"title":"Exit codes and their meanings","id":"exit-codes-and-their-meanings","level":2},{"title":"CLI Environment Variables","id":"cli-environment-variables","level":2},{"title":"WEBPACK_PACKAGE","id":"webpack_package","level":3},{"title":"Troubleshooting","id":"troubleshooting","level":2},{"title":"TypeError [ERR_UNKNOWN_FILE_EXTENSION]: Unknown file extension \\".ts\\" for ./webpack.config.ts","id":"typeerror-err_unknown_file_extension-unknown-file-extension-ts-for-webpackconfigts","level":3}],"title":"Command Line Interface","sort":1,"contributors":["anshumanv","rishabh3112","snitin315","evenstensberg","simon04","tbroadley","chenxsan","rencire","madhavarshney","EugeneHlushko","byzyk","wizardofhogwarts","EslamHiko","smelukov","anikethsaha","jamesgeorge007","burhanuday"],"related":[{"title":"Analyzing Build Statistics","url":"https://survivejs.com/webpack/optimizing-build/analyzing-build-statistics/"},{"title":"Three simple ways to inspect a webpack bundle","url":"https://medium.com/@joeclever/three-simple-ways-to-inspect-a-webpack-bundle-7f6a8fe7195d#.7d2i06mjx"},{"title":"Optimising your application bundle size with webpack","url":"https://hackernoon.com/optimising-your-application-bundle-size-with-webpack-e85b00bab579#.5w5ko08pq"},{"title":"Analysing and minimising the size of client-side bundle with webpack and source-map-explorer","url":"https://medium.com/@nimgrg/analysing-and-minimising-the-size-of-client-side-bundle-with-webpack-and-source-map-explorer-41096559beca#.c3t2srr8x"}]},{"path":"src/content/api/node.mdx","name":"node.mdx","size":9916,"type":"file","extension":".mdx","url":"/api/node/","anchors":[{"title":"Installation","id":"installation","level":2},{"title":"webpack()","id":"webpack","level":2},{"title":"Compiler Instance","id":"compiler-instance","level":2},{"title":"Run","id":"run","level":2},{"title":"Watching","id":"watching","level":2},{"title":"Close Watching","id":"close-watching","level":3},{"title":"Invalidate Watching","id":"invalidate-watching","level":3},{"title":"Stats Object","id":"stats-object","level":2},{"title":"stats.hasErrors()","id":"statshaserrors","level":3},{"title":"stats.hasWarnings()","id":"statshaswarnings","level":3},{"title":"stats.toJson(options)","id":"statstojsonoptions","level":3},{"title":"stats.toString(options)","id":"statstostringoptions","level":3},{"title":"MultiCompiler","id":"multicompiler","level":2},{"title":"Error Handling","id":"error-handling","level":2},{"title":"Custom File Systems","id":"custom-file-systems","level":2}],"title":"Node Interface","sort":2,"contributors":["sallar","rynclark","byzyk","wizardofhogwarts","EugeneHlushko","lukasgeiter","toshihidetagami","chenxsan","jamesgeorge007","textbook"]},{"path":"src/content/api/stats.mdx","name":"stats.mdx","size":11861,"type":"file","extension":".mdx","url":"/api/stats/","anchors":[{"title":"Structure","id":"structure","level":2},{"title":"Asset Objects","id":"asset-objects","level":3},{"title":"Chunk Objects","id":"chunk-objects","level":3},{"title":"Module Objects","id":"module-objects","level":3},{"title":"Entry Objects","id":"entry-objects","level":3},{"title":"Errors and Warnings","id":"errors-and-warnings","level":3}],"title":"Stats Data","sort":3,"contributors":["skipjack","franjohn21","byzyk","EugeneHlushko","superburrito","chenxsan","rahul3v","snitin315"]},{"path":"src/content/api/webpack-dev-server.mdx","name":"webpack-dev-server.mdx","size":4181,"type":"file","extension":".mdx","url":"/api/webpack-dev-server/","anchors":[{"title":"Installation","id":"installation","level":2},{"title":"start","id":"start","level":2},{"title":"startCallback(callback)","id":"startcallbackcallback","level":2},{"title":"stop","id":"stop","level":2},{"title":"stopCallback(callback)","id":"stopcallbackcallback","level":2},{"title":"internalIP(family: \\"v4\\" | \\"v6\\")","id":"internalipfamily-v4--v6","level":2},{"title":"internalIPSync(family: \\"v4\\" | \\"v6\\")","id":"internalipsyncfamily-v4--v6","level":2}],"title":"webpack-dev-server API","sort":3,"contributors":["snitin315"]},{"path":"src/content/api/hot-module-replacement.mdx","name":"hot-module-replacement.mdx","size":12482,"type":"file","extension":".mdx","url":"/api/hot-module-replacement/","anchors":[{"title":"Module API","id":"module-api","level":2},{"title":"accept","id":"accept","level":3},{"title":"accept (self)","id":"accept-self","level":3},{"title":"decline","id":"decline","level":3},{"title":"decline (self)","id":"decline-self","level":3},{"title":"dispose (or addDisposeHandler)","id":"dispose-or-adddisposehandler","level":3},{"title":"invalidate","id":"invalidate","level":3},{"title":"removeDisposeHandler","id":"removedisposehandler","level":3},{"title":"Management API","id":"management-api","level":2},{"title":"status","id":"status","level":3},{"title":"check","id":"check","level":3},{"title":"apply","id":"apply","level":3},{"title":"addStatusHandler","id":"addstatushandler","level":3},{"title":"removeStatusHandler","id":"removestatushandler","level":3}],"title":"Hot Module Replacement","sort":4,"contributors":["sokra","skipjack","tbroadley","byzyk","wizardofhogwarts","snitin315"],"related":[{"title":"Concepts - Hot Module Replacement","url":"/concepts/hot-module-replacement"},{"title":"Guides - Hot Module Replacement","url":"/guides/hot-module-replacement"}]},{"path":"src/content/api/loaders.mdx","name":"loaders.mdx","size":26784,"type":"file","extension":".mdx","url":"/api/loaders/","anchors":[{"title":"Examples","id":"examples","level":2},{"title":"Synchronous Loaders","id":"synchronous-loaders","level":3},{"title":"Asynchronous Loaders","id":"asynchronous-loaders","level":3},{"title":"\\"Raw\\" Loader","id":"raw-loader","level":3},{"title":"Pitching Loader","id":"pitching-loader","level":3},{"title":"The Loader Context","id":"the-loader-context","level":2},{"title":"Example for the loader context","id":"example-for-the-loader-context","level":3},{"title":"this.addContextDependency","id":"thisaddcontextdependency","level":3},{"title":"this.addDependency","id":"thisadddependency","level":3},{"title":"this.addMissingDependency","id":"thisaddmissingdependency","level":3},{"title":"this.async","id":"thisasync","level":3},{"title":"this.cacheable","id":"thiscacheable","level":3},{"title":"this.callback","id":"thiscallback","level":3},{"title":"this.clearDependencies","id":"thiscleardependencies","level":3},{"title":"this.context","id":"thiscontext","level":3},{"title":"this.data","id":"thisdata","level":3},{"title":"this.emitError","id":"thisemiterror","level":3},{"title":"this.emitFile","id":"thisemitfile","level":3},{"title":"this.emitWarning","id":"thisemitwarning","level":3},{"title":"this.environment","id":"thisenvironment","level":3},{"title":"this.fs","id":"thisfs","level":3},{"title":"this.getOptions(schema)","id":"thisgetoptionsschema","level":3},{"title":"this.getResolve","id":"thisgetresolve","level":3},{"title":"this.hot","id":"thishot","level":3},{"title":"this.importModule","id":"thisimportmodule","level":3},{"title":"this.loaderIndex","id":"thisloaderindex","level":3},{"title":"this.loadModule","id":"thisloadmodule","level":3},{"title":"this.loaders","id":"thisloaders","level":3},{"title":"this.mode","id":"thismode","level":3},{"title":"this.query","id":"thisquery","level":3},{"title":"this.request","id":"thisrequest","level":3},{"title":"this.resolve","id":"thisresolve","level":3},{"title":"this.resource","id":"thisresource","level":3},{"title":"this.resourcePath","id":"thisresourcepath","level":3},{"title":"this.resourceQuery","id":"thisresourcequery","level":3},{"title":"this.rootContext","id":"thisrootcontext","level":3},{"title":"this.sourceMap","id":"thissourcemap","level":3},{"title":"this.target","id":"thistarget","level":3},{"title":"this.utils","id":"thisutils","level":3},{"title":"this.version","id":"thisversion","level":3},{"title":"this.webpack","id":"thiswebpack","level":3},{"title":"Webpack specific properties","id":"webpack-specific-properties","level":2},{"title":"this._compilation","id":"this_compilation","level":3},{"title":"this._compiler","id":"this_compiler","level":3},{"title":"Deprecated context properties","id":"deprecated-context-properties","level":2},{"title":"this.debug","id":"thisdebug","level":3},{"title":"this.inputValue","id":"thisinputvalue","level":3},{"title":"this.minimize","id":"thisminimize","level":3},{"title":"this.value","id":"thisvalue","level":3},{"title":"this._module","id":"this_module","level":3},{"title":"Error Reporting","id":"error-reporting","level":2},{"title":"Inline matchResource","id":"inline-matchresource","level":2},{"title":"Logging","id":"logging","level":2}],"title":"Loader Interface","sort":5,"contributors":["TheLarkInn","jhnns","tbroadley","byzyk","sokra","EugeneHlushko","jantimon","superburrito","wizardofhogwarts","snitin315","chenxsan","jamesgeorge007"]},{"path":"src/content/api/logging.mdx","name":"logging.mdx","size":4597,"type":"file","extension":".mdx","url":"/api/logging/","anchors":[{"title":"Examples of how to get and use webpack logger in loaders and plugins","id":"examples-of-how-to-get-and-use-webpack-logger-in-loaders-and-plugins","level":2},{"title":"Logger methods","id":"logger-methods","level":2},{"title":"Runtime Logger API","id":"runtime-logger-api","level":2}],"title":"Logger Interface","sort":6,"contributors":["EugeneHlushko","wizardofhogwarts","chenxsan","snitin315"]},{"path":"src/content/api/module-methods.mdx","name":"module-methods.mdx","size":20293,"type":"file","extension":".mdx","url":"/api/module-methods/","anchors":[{"title":"ES6 (Recommended)","id":"es6-recommended","level":2},{"title":"import","id":"import","level":3},{"title":"export","id":"export","level":3},{"title":"import()","id":"import-1","level":3},{"title":"Dynamic expressions in import()","id":"dynamic-expressions-in-import","level":3},{"title":"CommonJS","id":"commonjs","level":2},{"title":"require","id":"require","level":3},{"title":"require.resolve","id":"requireresolve","level":3},{"title":"require.cache","id":"requirecache","level":3},{"title":"require.ensure","id":"requireensure","level":3},{"title":"AMD","id":"amd","level":2},{"title":"define (with factory)","id":"define-with-factory","level":3},{"title":"define (with value)","id":"define-with-value","level":3},{"title":"require (amd-version)","id":"require-amd-version","level":3},{"title":"Labeled Modules","id":"labeled-modules","level":2},{"title":"export label","id":"export-label","level":3},{"title":"require label","id":"require-label","level":3},{"title":"Webpack","id":"webpack","level":2},{"title":"require.context","id":"requirecontext","level":3},{"title":"require.include","id":"requireinclude","level":3},{"title":"require.resolveWeak","id":"requireresolveweak","level":3},{"title":"warning","id":"warning","level":3}],"title":"Module Methods","group":"Modules","sort":7,"contributors":["skipjack","sokra","fadysamirsadek","byzyk","debs-obrien","wizardofhogwarts","EugeneHlushko","chenxsan","jamesgeorge007","WofWca"],"related":[{"title":"CommonJS Wikipedia","url":"https://en.wikipedia.org/wiki/CommonJS"},{"title":"Asynchronous Module Definition","url":"https://en.wikipedia.org/wiki/Asynchronous_module_definition"}]},{"path":"src/content/api/module-variables.mdx","name":"module-variables.mdx","size":8539,"type":"file","extension":".mdx","url":"/api/module-variables/","anchors":[{"title":"module.loaded (NodeJS)","id":"moduleloaded-nodejs","level":2},{"title":"module.hot (webpack-specific)","id":"modulehot-webpack-specific","level":2},{"title":"module.id (CommonJS)","id":"moduleid-commonjs","level":2},{"title":"module.exports (CommonJS)","id":"moduleexports-commonjs","level":2},{"title":"exports (CommonJS)","id":"exports-commonjs","level":2},{"title":"global (NodeJS)","id":"global-nodejs","level":2},{"title":"__dirname (NodeJS)","id":"__dirname-nodejs","level":2},{"title":"import.meta","id":"importmeta","level":2},{"title":"import.meta.url","id":"importmetaurl","level":3},{"title":"import.meta.webpack","id":"importmetawebpack","level":3},{"title":"import.meta.webpackHot","id":"importmetawebpackhot","level":3},{"title":"import.meta.webpackContext","id":"importmetawebpackcontext","level":3},{"title":"__filename (NodeJS)","id":"__filename-nodejs","level":2},{"title":"__resourceQuery (webpack-specific)","id":"__resourcequery-webpack-specific","level":2},{"title":"__webpack_public_path__ (webpack-specific)","id":"__webpack_public_path__-webpack-specific","level":2},{"title":"__webpack_require__ (webpack-specific)","id":"__webpack_require__-webpack-specific","level":2},{"title":"__webpack_chunk_load__ (webpack-specific)","id":"__webpack_chunk_load__-webpack-specific","level":2},{"title":"__webpack_module__ (webpack-specific)","id":"__webpack_module__-webpack-specific","level":2},{"title":"__webpack_module__.id (webpack-specific)","id":"__webpack_module__id-webpack-specific","level":2},{"title":"__webpack_modules__ (webpack-specific)","id":"__webpack_modules__-webpack-specific","level":2},{"title":"__webpack_hash__ (webpack-specific)","id":"__webpack_hash__-webpack-specific","level":2},{"title":"__webpack_get_script_filename__ (webpack-specific)","id":"__webpack_get_script_filename__-webpack-specific","level":2},{"title":"__non_webpack_require__ (webpack-specific)","id":"__non_webpack_require__-webpack-specific","level":2},{"title":"__webpack_exports_info__ (webpack-specific)","id":"__webpack_exports_info__-webpack-specific","level":2},{"title":"__webpack_is_included__ (webpack-specific)","id":"__webpack_is_included__-webpack-specific","level":2},{"title":"__webpack_base_uri__ (webpack-specific)","id":"__webpack_base_uri__-webpack-specific","level":2},{"title":"__webpack_runtime_id__","id":"__webpack_runtime_id__","level":2},{"title":"DEBUG (webpack-specific)","id":"debug-webpack-specific","level":2}],"title":"Module Variables","group":"Modules","sort":8,"contributors":["skipjack","sokra","ahmehri","tbroadley","byzyk","EugeneHlushko","wizardofhogwarts","anikethsaha","chenxsan","jamesgeorge007","snitin315"],"related":[{"title":"CommonJS","url":"https://en.wikipedia.org/wiki/CommonJS"},{"title":"Asynchronous Module Definition","url":"https://en.wikipedia.org/wiki/Asynchronous_module_definition"}]},{"path":"src/content/api/compilation-object.mdx","name":"compilation-object.mdx","size":7134,"type":"file","extension":".mdx","url":"/api/compilation-object/","anchors":[{"title":"compilation object methods","id":"compilation-object-methods","level":2},{"title":"getStats","id":"getstats","level":3},{"title":"addModule","id":"addmodule","level":3},{"title":"getModule","id":"getmodule","level":3},{"title":"findModule","id":"findmodule","level":3},{"title":"buildModule","id":"buildmodule","level":3},{"title":"processModuleDependencies","id":"processmoduledependencies","level":3},{"title":"addEntry","id":"addentry","level":3},{"title":"rebuildModule","id":"rebuildmodule","level":3},{"title":"finish","id":"finish","level":3},{"title":"seal","id":"seal","level":3},{"title":"unseal","id":"unseal","level":3},{"title":"reportDependencyErrorsAndWarnings","id":"reportdependencyerrorsandwarnings","level":3},{"title":"addChunkInGroup","id":"addchunkingroup","level":3},{"title":"addChunk","id":"addchunk","level":3},{"title":"assignDepth","id":"assigndepth","level":3},{"title":"getDependencyReference","id":"getdependencyreference","level":3},{"title":"processDependenciesBlocksForChunkGroups","id":"processdependenciesblocksforchunkgroups","level":3},{"title":"removeReasonsOfDependencyBlock","id":"removereasonsofdependencyblock","level":3},{"title":"patchChunksAfterReasonRemoval","id":"patchchunksafterreasonremoval","level":3},{"title":"removeChunkFromDependencies","id":"removechunkfromdependencies","level":3},{"title":"sortItemsWithChunkIds","id":"sortitemswithchunkids","level":3},{"title":"summarizeDependencies","id":"summarizedependencies","level":3},{"title":"createHash","id":"createhash","level":3},{"title":"createModuleAssets","id":"createmoduleassets","level":3},{"title":"createChunkAssets","id":"createchunkassets","level":3},{"title":"getPath","id":"getpath","level":3},{"title":"getPathWithInfo","id":"getpathwithinfo","level":3},{"title":"createChildCompiler","id":"createchildcompiler","level":3},{"title":"checkConstraints","id":"checkconstraints","level":3},{"title":"emitAsset","id":"emitasset","level":3},{"title":"updateAsset","id":"updateasset","level":3},{"title":"deleteAsset","id":"deleteasset","level":3},{"title":"getAssets","id":"getassets","level":3},{"title":"getAsset","id":"getasset","level":3}],"title":"Compilation Object","group":"Objects","sort":14,"contributors":["EugeneHlushko","wizardofhogwarts","jamesgeorge007","snitin315"]},{"path":"src/content/api/compiler-hooks.mdx","name":"compiler-hooks.mdx","size":6946,"type":"file","extension":".mdx","url":"/api/compiler-hooks/","anchors":[{"title":"Watching","id":"watching","level":2},{"title":"Hooks","id":"hooks","level":2},{"title":"environment","id":"environment","level":3},{"title":"afterEnvironment","id":"afterenvironment","level":3},{"title":"entryOption","id":"entryoption","level":3},{"title":"afterPlugins","id":"afterplugins","level":3},{"title":"afterResolvers","id":"afterresolvers","level":3},{"title":"initialize","id":"initialize","level":3},{"title":"beforeRun","id":"beforerun","level":3},{"title":"run","id":"run","level":3},{"title":"watchRun","id":"watchrun","level":3},{"title":"normalModuleFactory","id":"normalmodulefactory","level":3},{"title":"contextModuleFactory","id":"contextmodulefactory","level":3},{"title":"beforeCompile","id":"beforecompile","level":3},{"title":"compile","id":"compile","level":3},{"title":"thisCompilation","id":"thiscompilation","level":3},{"title":"compilation","id":"compilation","level":3},{"title":"make","id":"make","level":3},{"title":"afterCompile","id":"aftercompile","level":3},{"title":"shouldEmit","id":"shouldemit","level":3},{"title":"emit","id":"emit","level":3},{"title":"afterEmit","id":"afteremit","level":3},{"title":"assetEmitted","id":"assetemitted","level":3},{"title":"done","id":"done","level":3},{"title":"additionalPass","id":"additionalpass","level":3},{"title":"failed","id":"failed","level":3},{"title":"invalid","id":"invalid","level":3},{"title":"watchClose","id":"watchclose","level":3},{"title":"shutdown","id":"shutdown","level":3},{"title":"infrastructureLog","id":"infrastructurelog","level":3},{"title":"log","id":"log","level":3}],"title":"Compiler Hooks","group":"Plugins","sort":9,"contributors":["rishantagarwal","byzyk","madhavarshney","misterdev","EugeneHlushko","superburrito","chenxsan"]},{"path":"src/content/api/compilation-hooks.mdx","name":"compilation-hooks.mdx","size":15807,"type":"file","extension":".mdx","url":"/api/compilation-hooks/","anchors":[{"title":"buildModule","id":"buildmodule","level":3},{"title":"rebuildModule","id":"rebuildmodule","level":3},{"title":"failedModule","id":"failedmodule","level":3},{"title":"succeedModule","id":"succeedmodule","level":3},{"title":"finishModules","id":"finishmodules","level":3},{"title":"finishRebuildingModule","id":"finishrebuildingmodule","level":3},{"title":"seal","id":"seal","level":3},{"title":"unseal","id":"unseal","level":3},{"title":"optimizeDependencies","id":"optimizedependencies","level":3},{"title":"afterOptimizeDependencies","id":"afteroptimizedependencies","level":3},{"title":"afterChunks","id":"afterchunks","level":3},{"title":"optimize","id":"optimize","level":3},{"title":"optimizeModules","id":"optimizemodules","level":3},{"title":"afterOptimizeModules","id":"afteroptimizemodules","level":3},{"title":"optimizeChunks","id":"optimizechunks","level":3},{"title":"afterOptimizeChunks","id":"afteroptimizechunks","level":3},{"title":"optimizeTree","id":"optimizetree","level":3},{"title":"afterOptimizeTree","id":"afteroptimizetree","level":3},{"title":"optimizeChunkModules","id":"optimizechunkmodules","level":3},{"title":"afterOptimizeChunkModules","id":"afteroptimizechunkmodules","level":3},{"title":"shouldRecord","id":"shouldrecord","level":3},{"title":"reviveModules","id":"revivemodules","level":3},{"title":"beforeModuleIds","id":"beforemoduleids","level":3},{"title":"moduleIds","id":"moduleids","level":3},{"title":"optimizeModuleIds","id":"optimizemoduleids","level":3},{"title":"afterOptimizeModuleIds","id":"afteroptimizemoduleids","level":3},{"title":"reviveChunks","id":"revivechunks","level":3},{"title":"beforeChunkIds","id":"beforechunkids","level":3},{"title":"chunkIds","id":"chunkids","level":3},{"title":"optimizeChunkIds","id":"optimizechunkids","level":3},{"title":"afterOptimizeChunkIds","id":"afteroptimizechunkids","level":3},{"title":"recordModules","id":"recordmodules","level":3},{"title":"recordChunks","id":"recordchunks","level":3},{"title":"beforeModuleHash","id":"beforemodulehash","level":3},{"title":"afterModuleHash","id":"aftermodulehash","level":3},{"title":"beforeHash","id":"beforehash","level":3},{"title":"afterHash","id":"afterhash","level":3},{"title":"recordHash","id":"recordhash","level":3},{"title":"record","id":"record","level":3},{"title":"beforeModuleAssets","id":"beforemoduleassets","level":3},{"title":"additionalChunkAssets","id":"additionalchunkassets","level":3},{"title":"shouldGenerateChunkAssets","id":"shouldgeneratechunkassets","level":3},{"title":"beforeChunkAssets","id":"beforechunkassets","level":3},{"title":"additionalAssets","id":"additionalassets","level":3},{"title":"optimizeChunkAssets","id":"optimizechunkassets","level":3},{"title":"afterOptimizeChunkAssets","id":"afteroptimizechunkassets","level":3},{"title":"optimizeAssets","id":"optimizeassets","level":3},{"title":"afterOptimizeAssets","id":"afteroptimizeassets","level":3},{"title":"processAssets","id":"processassets","level":3},{"title":"afterProcessAssets","id":"afterprocessassets","level":3},{"title":"needAdditionalSeal","id":"needadditionalseal","level":3},{"title":"afterSeal","id":"afterseal","level":3},{"title":"chunkHash","id":"chunkhash","level":3},{"title":"moduleAsset","id":"moduleasset","level":3},{"title":"chunkAsset","id":"chunkasset","level":3},{"title":"assetPath","id":"assetpath","level":3},{"title":"needAdditionalPass","id":"needadditionalpass","level":3},{"title":"childCompiler","id":"childcompiler","level":3},{"title":"normalModuleLoader","id":"normalmoduleloader","level":3}],"title":"Compilation Hooks","group":"Plugins","sort":10,"contributors":["slavafomin","byzyk","madhavarshney","misterdev","wizardofhogwarts","EugeneHlushko","chenxsan","jamesgeorge007"]},{"path":"src/content/api/contextmodulefactory-hooks.mdx","name":"contextmodulefactory-hooks.mdx","size":1531,"type":"file","extension":".mdx","url":"/api/contextmodulefactory-hooks/","anchors":[{"title":"beforeResolve","id":"beforeresolve","level":3},{"title":"afterResolve","id":"afterresolve","level":3},{"title":"contextModuleFiles","id":"contextmodulefiles","level":3},{"title":"alternativeRequests","id":"alternativerequests","level":3}],"title":"ContextModuleFactory Hooks","group":"Plugins","sort":11,"contributors":["iguessitsokay"]},{"path":"src/content/api/parser.mdx","name":"parser.mdx","size":9932,"type":"file","extension":".mdx","url":"/api/parser/","anchors":[{"title":"Hooks","id":"hooks","level":2},{"title":"evaluateTypeof","id":"evaluatetypeof","level":3},{"title":"evaluate","id":"evaluate","level":3},{"title":"evaluateIdentifier","id":"evaluateidentifier","level":3},{"title":"evaluateDefinedIdentifier","id":"evaluatedefinedidentifier","level":3},{"title":"evaluateCallExpressionMember","id":"evaluatecallexpressionmember","level":3},{"title":"statement","id":"statement","level":3},{"title":"statementIf","id":"statementif","level":3},{"title":"label","id":"label","level":3},{"title":"import","id":"import","level":3},{"title":"importSpecifier","id":"importspecifier","level":3},{"title":"export","id":"export","level":3},{"title":"exportImport","id":"exportimport","level":3},{"title":"exportDeclaration","id":"exportdeclaration","level":3},{"title":"exportExpression","id":"exportexpression","level":3},{"title":"exportSpecifier","id":"exportspecifier","level":3},{"title":"exportImportSpecifier","id":"exportimportspecifier","level":3},{"title":"varDeclaration","id":"vardeclaration","level":3},{"title":"varDeclarationLet","id":"vardeclarationlet","level":3},{"title":"varDeclarationConst","id":"vardeclarationconst","level":3},{"title":"varDeclarationVar","id":"vardeclarationvar","level":3},{"title":"canRename","id":"canrename","level":3},{"title":"rename","id":"rename","level":3},{"title":"assigned","id":"assigned","level":3},{"title":"assign","id":"assign","level":3},{"title":"typeof","id":"typeof","level":3},{"title":"call","id":"call","level":3},{"title":"callMemberChain","id":"callmemberchain","level":3},{"title":"new","id":"new","level":3},{"title":"expression","id":"expression","level":3},{"title":"expressionConditionalOperator","id":"expressionconditionaloperator","level":3},{"title":"program","id":"program","level":3}],"title":"JavascriptParser Hooks","group":"Plugins","sort":12,"contributors":["byzyk","DeTeam","misterdev","EugeneHlushko","chenxsan"]},{"path":"src/content/api/normalmodulefactory-hooks.mdx","name":"normalmodulefactory-hooks.mdx","size":3784,"type":"file","extension":".mdx","url":"/api/normalmodulefactory-hooks/","anchors":[{"title":"beforeResolve","id":"beforeresolve","level":3},{"title":"factorize","id":"factorize","level":3},{"title":"resolve","id":"resolve","level":3},{"title":"resolveForScheme","id":"resolveforscheme","level":3},{"title":"afterResolve","id":"afterresolve","level":3},{"title":"createModule","id":"createmodule","level":3},{"title":"createModuleClass","id":"createmoduleclass","level":3},{"title":"module","id":"module","level":3},{"title":"createParser","id":"createparser","level":3},{"title":"parser","id":"parser","level":3},{"title":"createGenerator","id":"creategenerator","level":3},{"title":"generator","id":"generator","level":3}],"title":"NormalModuleFactory Hooks","group":"Plugins","sort":13,"contributors":["iguessitsokay","chenxsan"]},{"path":"src/content/api/plugins.mdx","name":"plugins.mdx","size":6988,"type":"file","extension":".mdx","url":"/api/plugins/","anchors":[{"title":"Tapable","id":"tapable","level":2},{"title":"Plugin Types","id":"plugin-types","level":2},{"title":"Custom Hooks","id":"custom-hooks","level":2},{"title":"Reporting Progress","id":"reporting-progress","level":2},{"title":"Logging","id":"logging","level":2},{"title":"Next Steps","id":"next-steps","level":2}],"title":"Plugin API","group":"Plugins","sort":14,"contributors":["thelarkinn","pksjce","e-cloud","byzyk","EugeneHlushko","wizardofhogwarts","snitin315"]},{"path":"src/content/api/resolvers.mdx","name":"resolvers.mdx","size":2183,"type":"file","extension":".mdx","url":"/api/resolvers/","anchors":[{"title":"Types","id":"types","level":2},{"title":"Configuration Options","id":"configuration-options","level":2}],"title":"Resolvers","group":"Plugins","sort":15,"contributors":["EugeneHlushko","chenxsan"]}],"size":180840,"type":"directory","url":"/api/"},{"path":"src/content/blog","name":"blog","children":[{"path":"src/content/blog/2020-12-08-roadmap-2021.mdx","name":"2020-12-08-roadmap-2021.mdx","size":16371,"type":"file","extension":".mdx","url":"/blog/2020-12-08-roadmap-2021/","anchors":[{"title":"What happened so far?","id":"what-happened-so-far","level":2},{"title":"Roadmap 2021","id":"roadmap-2021","level":2},{"title":"Further stabilizing","id":"further-stabilizing","level":3},{"title":"EcmaScript Modules","id":"ecmascript-modules","level":3},{"title":"More first-class citizen","id":"more-first-class-citizen","level":3},{"title":"SourceMap performance","id":"sourcemap-performance","level":3},{"title":"exports/imports package.json field","id":"exportsimports-packagejson-field","level":3},{"title":"Improve CommonJS analysis","id":"improve-commonjs-analysis","level":3},{"title":"Hot Module Replacement for Module Federation","id":"hot-module-replacement-for-module-federation","level":3},{"title":"Hinting system","id":"hinting-system","level":3},{"title":"Multi-Threading","id":"multi-threading","level":3},{"title":"WebAssembly","id":"webassembly","level":3},{"title":"Disclaimer","id":"disclaimer","level":2}],"title":"Roadmap 2021 (2020-12-08)","sort":-202012080,"contributors":["sokra"]},{"path":"src/content/blog/2020-10-10-webpack-5-release.mdx","name":"2020-10-10-webpack-5-release.mdx","size":71620,"type":"file","extension":".mdx","url":"/blog/2020-10-10-webpack-5-release/","anchors":[{"title":"Common Questions","id":"common-questions","level":2},{"title":"So what does the release mean?","id":"so-what-does-the-release-mean","level":3},{"title":"So when is the time to upgrade?","id":"so-when-is-the-time-to-upgrade","level":3},{"title":"Sponsoring Update","id":"sponsoring-update","level":2},{"title":"General direction","id":"general-direction","level":2},{"title":"Migration Guide","id":"migration-guide","level":2},{"title":"Major Changes: Removals","id":"major-changes-removals","level":2},{"title":"Removed Deprecated Items","id":"removed-deprecated-items","level":3},{"title":"Deprecation codes","id":"deprecation-codes","level":3},{"title":"Syntax deprecated","id":"syntax-deprecated","level":3},{"title":"Automatic Node.js Polyfills Removed","id":"automatic-nodejs-polyfills-removed","level":3},{"title":"Major Changes: Long Term Caching","id":"major-changes-long-term-caching","level":2},{"title":"Deterministic Chunk, Module IDs and Export names","id":"deterministic-chunk-module-ids-and-export-names","level":3},{"title":"Real Content Hash","id":"real-content-hash","level":3},{"title":"Major Changes: Development Support","id":"major-changes-development-support","level":2},{"title":"Named Chunk IDs","id":"named-chunk-ids","level":3},{"title":"Module Federation","id":"module-federation","level":3},{"title":"Major Changes: New Web Platform Features","id":"major-changes-new-web-platform-features","level":2},{"title":"JSON modules","id":"json-modules","level":3},{"title":"import.meta","id":"importmeta","level":3},{"title":"Asset modules","id":"asset-modules","level":3},{"title":"Native Worker support","id":"native-worker-support","level":3},{"title":"URIs","id":"uris","level":3},{"title":"Async modules","id":"async-modules","level":3},{"title":"Externals","id":"externals","level":3},{"title":"Major Changes: New Node.js Ecosystem Features","id":"major-changes-new-nodejs-ecosystem-features","level":2},{"title":"Resolving","id":"resolving","level":3},{"title":"Major Changes: Development Experience","id":"major-changes-development-experience","level":2},{"title":"Improved target","id":"improved-target","level":3},{"title":"Stats","id":"stats","level":3},{"title":"Progress","id":"progress","level":3},{"title":"Automatic unique naming","id":"automatic-unique-naming","level":3},{"title":"Automatic public path","id":"automatic-public-path","level":3},{"title":"Typescript typings","id":"typescript-typings","level":3},{"title":"Major Changes: Optimization","id":"major-changes-optimization","level":2},{"title":"Nested tree-shaking","id":"nested-tree-shaking","level":3},{"title":"Inner-module tree-shaking","id":"inner-module-tree-shaking","level":3},{"title":"CommonJs Tree Shaking","id":"commonjs-tree-shaking","level":3},{"title":"Side-Effect analysis","id":"side-effect-analysis","level":3},{"title":"Optimization per runtime","id":"optimization-per-runtime","level":3},{"title":"Module Concatenation","id":"module-concatenation","level":3},{"title":"General Tree Shaking improvements","id":"general-tree-shaking-improvements","level":3},{"title":"Development Production Similarity","id":"development-production-similarity","level":3},{"title":"Improved Code Generation","id":"improved-code-generation","level":3},{"title":"Improved target option","id":"improved-target-option","level":3},{"title":"SplitChunks and Module Sizes","id":"splitchunks-and-module-sizes","level":3},{"title":"Major Changes: Performance","id":"major-changes-performance","level":2},{"title":"Persistent Caching","id":"persistent-caching","level":3},{"title":"File Emitting","id":"file-emitting","level":3},{"title":"Major Changes: Long outstanding problems","id":"major-changes-long-outstanding-problems","level":2},{"title":"Code Splitting for single-file-targets","id":"code-splitting-for-single-file-targets","level":3},{"title":"Updated Resolver","id":"updated-resolver","level":3},{"title":"Chunks without JS","id":"chunks-without-js","level":3},{"title":"Major Changes: Future","id":"major-changes-future","level":2},{"title":"Experiments","id":"experiments","level":3},{"title":"Minimum Node.js Version","id":"minimum-nodejs-version","level":3},{"title":"Changes to the Configuration","id":"changes-to-the-configuration","level":2},{"title":"Changes to the Structure","id":"changes-to-the-structure","level":3},{"title":"Changes to the Defaults","id":"changes-to-the-defaults","level":3},{"title":"Loader related Changes","id":"loader-related-changes","level":2},{"title":"this.getOptions","id":"thisgetoptions","level":3},{"title":"this.exec","id":"thisexec","level":3},{"title":"this.getResolve","id":"thisgetresolve","level":3},{"title":"Major Internal Changes","id":"major-internal-changes","level":2},{"title":"New plugin order","id":"new-plugin-order","level":3},{"title":"Runtime Modules","id":"runtime-modules","level":3},{"title":"Serialization","id":"serialization","level":3},{"title":"Plugins for Caching","id":"plugins-for-caching","level":3},{"title":"Hook Object Frozen","id":"hook-object-frozen","level":3},{"title":"Tapable Upgrade","id":"tapable-upgrade","level":3},{"title":"Staged Hooks","id":"staged-hooks","level":3},{"title":"Main/Chunk/ModuleTemplate deprecation","id":"mainchunkmoduletemplate-deprecation","level":3},{"title":"Entry point descriptor","id":"entry-point-descriptor","level":3},{"title":"Order and IDs","id":"order-and-ids","level":3},{"title":"Arrays to Sets","id":"arrays-to-sets","level":3},{"title":"Compilation.fileSystemInfo","id":"compilationfilesysteminfo","level":3},{"title":"Filesystems","id":"filesystems","level":3},{"title":"Hot Module Replacement","id":"hot-module-replacement","level":3},{"title":"Work Queues","id":"work-queues","level":3},{"title":"Logging","id":"logging","level":3},{"title":"Module and Chunk Graph","id":"module-and-chunk-graph","level":3},{"title":"Init Fragments","id":"init-fragments","level":3},{"title":"Module Source Types","id":"module-source-types","level":3},{"title":"Plugins for Stats","id":"plugins-for-stats","level":3},{"title":"New Watching","id":"new-watching","level":3},{"title":"SizeOnlySource after emit","id":"sizeonlysource-after-emit","level":3},{"title":"Emitting assets multiple times","id":"emitting-assets-multiple-times","level":3},{"title":"ExportsInfo","id":"exportsinfo","level":3},{"title":"Code Generation Phase","id":"code-generation-phase","level":3},{"title":"DependencyReference","id":"dependencyreference","level":3},{"title":"Presentational Dependencies","id":"presentational-dependencies","level":3},{"title":"Deprecated loaders","id":"deprecated-loaders","level":3},{"title":"Minor Changes","id":"minor-changes","level":2},{"title":"Other Minor Changes","id":"other-minor-changes","level":2}],"title":"Webpack 5 release (2020-10-10)","sort":-202010100,"contributors":["sokra","chenxsan"]},{"path":"src/content/blog/index.mdx","name":"index.mdx","size":214,"type":"file","extension":".mdx","url":"/blog/","anchors":[{"title":"Popular posts","id":"popular-posts","level":2}],"title":"Blog","sort":-1,"contributors":["sokra"]}],"size":88205,"type":"directory","url":"/blog/"},{"path":"src/content/concepts","name":"concepts","children":[{"path":"src/content/concepts/index.mdx","name":"index.mdx","size":7732,"type":"file","extension":".mdx","url":"/concepts/","anchors":[{"title":"Entry","id":"entry","level":2},{"title":"Output","id":"output","level":2},{"title":"Loaders","id":"loaders","level":2},{"title":"Plugins","id":"plugins","level":2},{"title":"Mode","id":"mode","level":2},{"title":"Browser Compatibility","id":"browser-compatibility","level":2},{"title":"Environment","id":"environment","level":2}],"title":"Concepts","sort":-1,"contributors":["TheLarkInn","jhnns","grgur","johnstew","jimrfenner","TheDutchCoder","adambraimbridge","EugeneHlushko","jeremenichelli","arjunsajeev","byzyk","yairhaimo","farskid","LukeMwila","Jalitha","muhmushtaha","chenxsan","RyanGreyling2"]},{"path":"src/content/concepts/entry-points.mdx","name":"entry-points.mdx","size":6616,"type":"file","extension":".mdx","url":"/concepts/entry-points/","anchors":[{"title":"Single Entry (Shorthand) Syntax","id":"single-entry-shorthand-syntax","level":2},{"title":"Object Syntax","id":"object-syntax","level":2},{"title":"EntryDescription object","id":"entrydescription-object","level":3},{"title":"Scenarios","id":"scenarios","level":2},{"title":"Separate App and Vendor Entries","id":"separate-app-and-vendor-entries","level":3},{"title":"Multi-Page Application","id":"multi-page-application","level":3}],"title":"Entry Points","sort":1,"contributors":["TheLarkInn","chrisVillanueva","byzyk","sokra","EugeneHlushko","Zearin","chenxsan","adyjs","anshumanv","ritikbanger"]},{"path":"src/content/concepts/output.mdx","name":"output.mdx","size":1840,"type":"file","extension":".mdx","url":"/concepts/output/","anchors":[{"title":"Usage","id":"usage","level":2},{"title":"Multiple Entry Points","id":"multiple-entry-points","level":2},{"title":"Advanced","id":"advanced","level":2}],"title":"Output","sort":2,"contributors":["TheLarkInn","chyipin","rouzbeh84","byzyk","EugeneHlushko"]},{"path":"src/content/concepts/loaders.mdx","name":"loaders.mdx","size":5546,"type":"file","extension":".mdx","url":"/concepts/loaders/","anchors":[{"title":"Example","id":"example","level":2},{"title":"Using Loaders","id":"using-loaders","level":2},{"title":"Configuration","id":"configuration","level":3},{"title":"Inline","id":"inline","level":3},{"title":"Loader Features","id":"loader-features","level":2},{"title":"Resolving Loaders","id":"resolving-loaders","level":2}],"title":"Loaders","sort":3,"contributors":["manekinekko","evenstensberg","SpaceK33z","gangachris","TheLarkInn","simon04","jhnns","byzyk","debs-obrien","EugeneHlushko","wizardofhogwarts","lukasgeiter","furkle","jamesgeorge007","textbook"]},{"path":"src/content/concepts/plugins.mdx","name":"plugins.mdx","size":3373,"type":"file","extension":".mdx","url":"/concepts/plugins/","anchors":[{"title":"Anatomy","id":"anatomy","level":2},{"title":"Usage","id":"usage","level":2},{"title":"Configuration","id":"configuration","level":3},{"title":"Node API","id":"node-api","level":3}],"title":"Plugins","sort":4,"contributors":["TheLarkInn","jhnns","rouzbeh84","johnstew","MisterDev","byzyk","chenxsan"]},{"path":"src/content/concepts/configuration.mdx","name":"configuration.mdx","size":2448,"type":"file","extension":".mdx","url":"/concepts/configuration/","anchors":[{"title":"Introductory Configuration","id":"introductory-configuration","level":2},{"title":"Multiple Targets","id":"multiple-targets","level":2},{"title":"Using other Configuration Languages","id":"using-other-configuration-languages","level":2}],"title":"Configuration","sort":5,"contributors":["TheLarkInn","simon04","EugeneHlushko","byzyk"]},{"path":"src/content/concepts/modules.mdx","name":"modules.mdx","size":2898,"type":"file","extension":".mdx","url":"/concepts/modules/","anchors":[{"title":"What is a webpack Module","id":"what-is-a-webpack-module","level":2},{"title":"Supported Module Types","id":"supported-module-types","level":2}],"title":"Modules","sort":6,"contributors":["TheLarkInn","simon04","rouzbeh84","EugeneHlushko","byzyk"],"related":[{"title":"JavaScript Module Systems Showdown","url":"https://auth0.com/blog/javascript-module-systems-showdown/"}]},{"path":"src/content/concepts/module-resolution.mdx","name":"module-resolution.mdx","size":4080,"type":"file","extension":".mdx","url":"/concepts/module-resolution/","anchors":[{"title":"Resolving rules in webpack","id":"resolving-rules-in-webpack","level":2},{"title":"Absolute paths","id":"absolute-paths","level":3},{"title":"Relative paths","id":"relative-paths","level":3},{"title":"Module paths","id":"module-paths","level":3},{"title":"Resolving Loaders","id":"resolving-loaders","level":2},{"title":"Caching","id":"caching","level":2}],"title":"Module Resolution","sort":7,"contributors":["pksjce","pastelsky","byzyk","EugeneHlushko","wizardofhogwarts"]},{"path":"src/content/concepts/module-federation.mdx","name":"module-federation.mdx","size":14602,"type":"file","extension":".mdx","url":"/concepts/module-federation/","anchors":[{"title":"Motivation","id":"motivation","level":2},{"title":"Low-level concepts","id":"low-level-concepts","level":2},{"title":"High-level concepts","id":"high-level-concepts","level":2},{"title":"Building blocks","id":"building-blocks","level":2},{"title":"ContainerPlugin (low level)","id":"containerplugin-low-level","level":3},{"title":"ContainerReferencePlugin (low level)","id":"containerreferenceplugin-low-level","level":3},{"title":"ModuleFederationPlugin (high level)","id":"modulefederationplugin-high-level","level":3},{"title":"Concept goals","id":"concept-goals","level":2},{"title":"Use cases","id":"use-cases","level":2},{"title":"Separate builds per page","id":"separate-builds-per-page","level":3},{"title":"Components library as container","id":"components-library-as-container","level":3},{"title":"Dynamic Remote Containers","id":"dynamic-remote-containers","level":2},{"title":"Promise Based Dynamic Remotes","id":"promise-based-dynamic-remotes","level":2},{"title":"Dynamic Public Path","id":"dynamic-public-path","level":2},{"title":"Offer a host API to set the publicPath","id":"offer-a-host-api-to-set-the-publicpath","level":3},{"title":"Infer publicPath from script","id":"infer-publicpath-from-script","level":3},{"title":"Troubleshooting","id":"troubleshooting","level":2},{"title":"Uncaught Error: Shared module is not available for eager consumption","id":"uncaught-error-shared-module-is-not-available-for-eager-consumption","level":3},{"title":"Uncaught Error: Module \\"./Button\\" does not exist in container.","id":"uncaught-error-module-button-does-not-exist-in-container","level":3},{"title":"Uncaught TypeError: fn is not a function","id":"uncaught-typeerror-fn-is-not-a-function","level":3},{"title":"Collision between modules from different remotes","id":"collision-between-modules-from-different-remotes","level":3}],"title":"Module Federation","sort":8,"contributors":["sokra","chenxsan","EugeneHlushko","jamesgeorge007","ScriptedAlchemy","snitin315","XiaofengXie16","KyleBastien","Alevale","burhanuday"],"related":[{"title":"Webpack 5 Module Federation: A game-changer in JavaScript architecture","url":"https://medium.com/swlh/webpack-5-module-federation-a-game-changer-to-javascript-architecture-bcdd30e02669"},{"title":"Explanations and Examples","url":"https://github.com/module-federation/module-federation-examples"},{"title":"Module Federation YouTube Playlist","url":"https://www.youtube.com/playlist?list=PLWSiF9YHHK-DqsFHGYbeAMwbd9xcZbEWJ"}]},{"path":"src/content/concepts/dependency-graph.mdx","name":"dependency-graph.mdx","size":1223,"type":"file","extension":".mdx","url":"/concepts/dependency-graph/","anchors":[],"title":"Dependency Graph","sort":9,"contributors":["TheLarkInn","EugeneHlushko"],"related":[{"title":"HTTP2 Aggressive Splitting Example","url":"https://github.com/webpack/webpack/tree/master/examples/http2-aggressive-splitting"},{"title":"webpack & HTTP/2","url":"https://medium.com/webpack/webpack-http-2-7083ec3f3ce6"}]},{"path":"src/content/concepts/targets.mdx","name":"targets.mdx","size":2462,"type":"file","extension":".mdx","url":"/concepts/targets/","anchors":[{"title":"Usage","id":"usage","level":2},{"title":"Multiple Targets","id":"multiple-targets","level":2},{"title":"Resources","id":"resources","level":2}],"title":"Targets","sort":10,"contributors":["TheLarkInn","rouzbeh84","johnstew","srilman","byzyk","EugeneHlushko"]},{"path":"src/content/concepts/manifest.mdx","name":"manifest.mdx","size":3393,"type":"file","extension":".mdx","url":"/concepts/manifest/","anchors":[{"title":"Runtime","id":"runtime","level":2},{"title":"Manifest","id":"manifest","level":2},{"title":"The Problem","id":"the-problem","level":2}],"title":"The Manifest","sort":11,"contributors":["skipjack","EugeneHlushko"],"related":[{"title":"Separating a Manifest","url":"https://survivejs.com/webpack/optimizing/separating-manifest/"},{"title":"Predictable Long Term Caching with webpack","url":"https://medium.com/webpack/predictable-long-term-caching-with-webpack-d3eee1d3fa31"},{"title":"Caching","url":"/guides/caching/"}]},{"path":"src/content/concepts/hot-module-replacement.mdx","name":"hot-module-replacement.mdx","size":4931,"type":"file","extension":".mdx","url":"/concepts/hot-module-replacement/","anchors":[{"title":"How It Works","id":"how-it-works","level":2},{"title":"In the Application","id":"in-the-application","level":3},{"title":"In the Compiler","id":"in-the-compiler","level":3},{"title":"In a Module","id":"in-a-module","level":3},{"title":"In the Runtime","id":"in-the-runtime","level":3},{"title":"Get Started","id":"get-started","level":2}],"title":"Hot Module Replacement","sort":12,"contributors":["kryptokinght","SpaceK33z","sokra","GRardB","rouzbeh84","skipjack"]},{"path":"src/content/concepts/why-webpack.mdx","name":"why-webpack.mdx","size":4124,"type":"file","extension":".mdx","url":"/concepts/why-webpack/","anchors":[{"title":"IIFEs - Immediately invoked function expressions","id":"iifes---immediately-invoked-function-expressions","level":2},{"title":"Birth of JavaScript Modules happened thanks to Node.js","id":"birth-of-javascript-modules-happened-thanks-to-nodejs","level":2},{"title":"npm + Node.js + modules – mass distribution","id":"npm--nodejs--modules--mass-distribution","level":2},{"title":"ESM - ECMAScript Modules","id":"esm---ecmascript-modules","level":2},{"title":"Automatic Dependency Collection","id":"automatic-dependency-collection","level":2},{"title":"Wouldn\'t it be nice…","id":"wouldnt-it-be-nice","level":2}],"title":"Why webpack","sort":13,"contributors":["debs-obrien","montogeek","jeremenichelli","EugeneHlushko"]},{"path":"src/content/concepts/under-the-hood.mdx","name":"under-the-hood.mdx","size":3980,"type":"file","extension":".mdx","url":"/concepts/under-the-hood/","anchors":[{"title":"The main parts","id":"the-main-parts","level":2},{"title":"Chunks","id":"chunks","level":2},{"title":"Output","id":"output","level":2}],"title":"Under The Hood","sort":14,"contributors":["smelukov","EugeneHlushko","chenxsan","amirsaeed671"]}],"size":69248,"type":"directory","url":"/concepts/"},{"path":"src/content/configuration","name":"configuration","children":[{"path":"src/content/configuration/index.mdx","name":"index.mdx","size":3489,"type":"file","extension":".mdx","url":"/configuration/","anchors":[{"title":"Use a different configuration file","id":"use-a-different-configuration-file","level":2},{"title":"Set up a new webpack project","id":"set-up-a-new-webpack-project","level":2}],"title":"Configuration","sort":1,"contributors":["sokra","skipjack","grgur","bondz","sricc","terinjokes","mattce","kbariotis","sterlingvix","jeremenichelli","dasarianudeep","lukasgeiter","EugeneHlushko","bigdawggi","anshumanv","textbook","coly010","chenxsan"]},{"path":"src/content/configuration/configuration-languages.mdx","name":"configuration-languages.mdx","size":5756,"type":"file","extension":".mdx","url":"/configuration/configuration-languages/","anchors":[{"title":"TypeScript","id":"typescript","level":2},{"title":"CoffeeScript","id":"coffeescript","level":2},{"title":"Babel and JSX","id":"babel-and-jsx","level":2}],"title":"Configuration Languages","sort":2,"contributors":["piouson","sokra","skipjack","tarang9211","simon04","peterblazejewicz","youta1119","byzyk","Nek-","liyiming22","daimalou","ChocolateLoverRaj","snitin315"]},{"path":"src/content/configuration/configuration-types.mdx","name":"configuration-types.mdx","size":3714,"type":"file","extension":".mdx","url":"/configuration/configuration-types/","anchors":[{"title":"Exporting a Function","id":"exporting-a-function","level":2},{"title":"Exporting a Promise","id":"exporting-a-promise","level":2},{"title":"Exporting multiple configurations","id":"exporting-multiple-configurations","level":2},{"title":"dependencies","id":"dependencies","level":3},{"title":"parallelism","id":"parallelism","level":3}],"title":"Configuration Types","sort":3,"contributors":["sokra","skipjack","kbariotis","simon04","fadysamirsadek","byzyk","EugeneHlushko","dhurlburtusa","anshumanv","thorn0"]},{"path":"src/content/configuration/entry-context.mdx","name":"entry-context.mdx","size":5075,"type":"file","extension":".mdx","url":"/configuration/entry-context/","anchors":[{"title":"context","id":"context","level":2},{"title":"entry","id":"entry","level":2},{"title":"Naming","id":"naming","level":3},{"title":"Entry descriptor","id":"entry-descriptor","level":3},{"title":"Output filename","id":"output-filename","level":3},{"title":"Dependencies","id":"dependencies","level":3},{"title":"Dynamic entry","id":"dynamic-entry","level":3}],"title":"Entry and Context","sort":4,"contributors":["sokra","skipjack","tarang9211","byzyk","madhavarshney","EugeneHlushko","smelukov","anshumanv","snitin315"]},{"path":"src/content/configuration/mode.mdx","name":"mode.mdx","size":2960,"type":"file","extension":".mdx","url":"/configuration/mode/","anchors":[{"title":"Usage","id":"usage","level":2},{"title":"Mode: development","id":"mode-development","level":3},{"title":"Mode: production","id":"mode-production","level":3},{"title":"Mode: none","id":"mode-none","level":3}],"title":"Mode","sort":5,"contributors":["EugeneHlushko","byzyk","mrichmond","Fental","snitin315","chenxsan"],"related":[{"title":"webpack default options (source code)","url":"https://github.com/webpack/webpack/blob/main/lib/config/defaults.js"}]},{"path":"src/content/configuration/output.mdx","name":"output.mdx","size":70419,"type":"file","extension":".mdx","url":"/configuration/output/","anchors":[{"title":"output.assetModuleFilename","id":"outputassetmodulefilename","level":2},{"title":"output.asyncChunks","id":"outputasyncchunks","level":2},{"title":"output.auxiliaryComment","id":"outputauxiliarycomment","level":2},{"title":"output.charset","id":"outputcharset","level":2},{"title":"output.chunkFilename","id":"outputchunkfilename","level":2},{"title":"output.chunkFormat","id":"outputchunkformat","level":2},{"title":"output.chunkLoadTimeout","id":"outputchunkloadtimeout","level":2},{"title":"output.chunkLoadingGlobal","id":"outputchunkloadingglobal","level":2},{"title":"output.chunkLoading","id":"outputchunkloading","level":2},{"title":"output.clean","id":"outputclean","level":2},{"title":"output.compareBeforeEmit","id":"outputcomparebeforeemit","level":2},{"title":"output.crossOriginLoading","id":"outputcrossoriginloading","level":2},{"title":"output.devtoolFallbackModuleFilenameTemplate","id":"outputdevtoolfallbackmodulefilenametemplate","level":2},{"title":"output.devtoolModuleFilenameTemplate","id":"outputdevtoolmodulefilenametemplate","level":2},{"title":"output.devtoolNamespace","id":"outputdevtoolnamespace","level":2},{"title":"output.enabledChunkLoadingTypes","id":"outputenabledchunkloadingtypes","level":2},{"title":"output.enabledLibraryTypes","id":"outputenabledlibrarytypes","level":2},{"title":"output.enabledWasmLoadingTypes","id":"outputenabledwasmloadingtypes","level":2},{"title":"output.environment","id":"outputenvironment","level":2},{"title":"output.filename","id":"outputfilename","level":2},{"title":"Template strings","id":"template-strings","level":3},{"title":"output.globalObject","id":"outputglobalobject","level":2},{"title":"output.hashDigest","id":"outputhashdigest","level":2},{"title":"output.hashDigestLength","id":"outputhashdigestlength","level":2},{"title":"output.hashFunction","id":"outputhashfunction","level":2},{"title":"output.hashSalt","id":"outputhashsalt","level":2},{"title":"output.hotUpdateChunkFilename","id":"outputhotupdatechunkfilename","level":2},{"title":"output.hotUpdateGlobal","id":"outputhotupdateglobal","level":2},{"title":"output.hotUpdateMainFilename","id":"outputhotupdatemainfilename","level":2},{"title":"output.iife","id":"outputiife","level":2},{"title":"output.ignoreBrowserWarnings","id":"outputignorebrowserwarnings","level":2},{"title":"output.importFunctionName","id":"outputimportfunctionname","level":2},{"title":"output.library","id":"outputlibrary","level":2},{"title":"output.library.amdContainer","id":"outputlibraryamdcontainer","level":3},{"title":"output.library.name","id":"outputlibraryname","level":3},{"title":"output.library.type","id":"outputlibrarytype","level":3},{"title":"output.library.export","id":"outputlibraryexport","level":3},{"title":"output.library.auxiliaryComment","id":"outputlibraryauxiliarycomment","level":3},{"title":"output.library.umdNamedDefine","id":"outputlibraryumdnameddefine","level":3},{"title":"output.libraryExport","id":"outputlibraryexport-1","level":2},{"title":"output.libraryTarget","id":"outputlibrarytarget","level":2},{"title":"Expose a Variable","id":"expose-a-variable-1","level":3},{"title":"Expose Via Object Assignment","id":"expose-via-object-assignment-1","level":3},{"title":"Module Definition Systems","id":"module-definition-systems-1","level":3},{"title":"Other Targets","id":"other-targets","level":3},{"title":"output.module","id":"outputmodule","level":2},{"title":"output.path","id":"outputpath","level":2},{"title":"output.pathinfo","id":"outputpathinfo","level":2},{"title":"output.publicPath","id":"outputpublicpath","level":2},{"title":"output.scriptType","id":"outputscripttype","level":2},{"title":"output.sourceMapFilename","id":"outputsourcemapfilename","level":2},{"title":"output.sourcePrefix","id":"outputsourceprefix","level":2},{"title":"output.strictModuleErrorHandling","id":"outputstrictmoduleerrorhandling","level":2},{"title":"output.strictModuleExceptionHandling","id":"outputstrictmoduleexceptionhandling","level":2},{"title":"output.trustedTypes","id":"outputtrustedtypes","level":2},{"title":"output.trustedTypes.onPolicyCreationFailure","id":"outputtrustedtypesonpolicycreationfailure","level":3},{"title":"output.umdNamedDefine","id":"outputumdnameddefine","level":2},{"title":"output.uniqueName","id":"outputuniquename","level":2},{"title":"output.wasmLoading","id":"outputwasmloading","level":2},{"title":"output.workerChunkLoading","id":"outputworkerchunkloading","level":2},{"title":"output.workerPublicPath","id":"outputworkerpublicpath","level":2}],"title":"Output","sort":6,"contributors":["sokra","skipjack","tomasAlabes","mattce","irth","fvgs","dhurlburtusa","MagicDuck","fadysamirsadek","byzyk","madhavarshney","harshwardhansingh","eemeli","EugeneHlushko","g-plane","smelukov","Neob91","anikethsaha","jamesgeorge007","hiroppy","chenxsan","snitin315","QC-L","anshumanv","mrzalyaul","JakobJingleheimer","long76"]},{"path":"src/content/configuration/module.mdx","name":"module.mdx","size":36956,"type":"file","extension":".mdx","url":"/configuration/module/","anchors":[{"title":"module.defaultRules","id":"moduledefaultrules","level":2},{"title":"module.generator","id":"modulegenerator","level":2},{"title":"module.parser","id":"moduleparser","level":2},{"title":"module.parser.javascript","id":"moduleparserjavascript","level":3},{"title":"module.noParse","id":"modulenoparse","level":2},{"title":"module.unsafeCache","id":"moduleunsafecache","level":2},{"title":"module.rules","id":"modulerules","level":2},{"title":"Rule","id":"rule","level":2},{"title":"Rule Conditions","id":"rule-conditions","level":3},{"title":"Rule results","id":"rule-results","level":3},{"title":"Nested rules","id":"nested-rules","level":2},{"title":"Rule.enforce","id":"ruleenforce","level":2},{"title":"Rule.exclude","id":"ruleexclude","level":2},{"title":"Rule.include","id":"ruleinclude","level":2},{"title":"Rule.issuer","id":"ruleissuer","level":2},{"title":"Rule.issuerLayer","id":"ruleissuerlayer","level":2},{"title":"Rule.layer","id":"rulelayer","level":2},{"title":"Rule.loader","id":"ruleloader","level":2},{"title":"Rule.loaders","id":"ruleloaders","level":2},{"title":"Rule.mimetype","id":"rulemimetype","level":2},{"title":"Rule.oneOf","id":"ruleoneof","level":2},{"title":"Rule.options / Rule.query","id":"ruleoptions--rulequery","level":2},{"title":"Rule.parser","id":"ruleparser","level":2},{"title":"Rule.parser.dataUrlCondition","id":"ruleparserdataurlcondition","level":2},{"title":"Rule.generator","id":"rulegenerator","level":2},{"title":"Rule.generator.dataUrl","id":"rulegeneratordataurl","level":3},{"title":"Rule.generator.emit","id":"rulegeneratoremit","level":3},{"title":"Rule.generator.filename","id":"rulegeneratorfilename","level":3},{"title":"Rule.generator.publicPath","id":"rulegeneratorpublicpath","level":3},{"title":"Rule.generator.outputPath","id":"rulegeneratoroutputpath","level":3},{"title":"Rule.resource","id":"ruleresource","level":2},{"title":"Rule.resourceQuery","id":"ruleresourcequery","level":2},{"title":"Rule.parser.parse","id":"ruleparserparse","level":2},{"title":"Rule.rules","id":"rulerules","level":2},{"title":"Rule.scheme","id":"rulescheme","level":2},{"title":"Rule.sideEffects","id":"rulesideeffects","level":2},{"title":"Rule.test","id":"ruletest","level":2},{"title":"Rule.type","id":"ruletype","level":2},{"title":"css/auto","id":"cssauto","level":3},{"title":"Rule.use","id":"ruleuse","level":2},{"title":"Rule.resolve","id":"ruleresolve","level":2},{"title":"resolve.fullySpecified","id":"resolvefullyspecified","level":3},{"title":"Condition","id":"condition","level":2},{"title":"UseEntry","id":"useentry","level":2},{"title":"Module Contexts","id":"module-contexts","level":2}],"title":"Module","sort":7,"contributors":["sokra","skipjack","jouni-kantola","jhnns","dylanonelson","byzyk","pnevares","fadysamirsadek","nerdkid93","EugeneHlushko","superburrito","lukasgeiter","skovy","smelukov","opl-","Mistyyyy","anshumanv","chenxsan","snitin315","vabushkevich"]},{"path":"src/content/configuration/resolve.mdx","name":"resolve.mdx","size":17803,"type":"file","extension":".mdx","url":"/configuration/resolve/","anchors":[{"title":"resolve","id":"resolve","level":2},{"title":"resolve.alias","id":"resolvealias","level":3},{"title":"resolve.aliasFields","id":"resolvealiasfields","level":3},{"title":"resolve.cacheWithContext","id":"resolvecachewithcontext","level":3},{"title":"resolve.conditionNames","id":"resolveconditionnames","level":3},{"title":"resolve.descriptionFiles","id":"resolvedescriptionfiles","level":3},{"title":"resolve.enforceExtension","id":"resolveenforceextension","level":3},{"title":"resolve.extensionAlias","id":"resolveextensionalias","level":3},{"title":"resolve.extensions","id":"resolveextensions","level":3},{"title":"resolve.fallback","id":"resolvefallback","level":3},{"title":"resolve.mainFields","id":"resolvemainfields","level":3},{"title":"resolve.mainFiles","id":"resolvemainfiles","level":3},{"title":"resolve.exportsFields","id":"resolveexportsfields","level":3},{"title":"resolve.modules","id":"resolvemodules","level":3},{"title":"resolve.unsafeCache","id":"resolveunsafecache","level":3},{"title":"resolve.useSyncFileSystemCalls","id":"resolveusesyncfilesystemcalls","level":3},{"title":"resolve.plugins","id":"resolveplugins","level":3},{"title":"resolve.preferRelative","id":"resolvepreferrelative","level":3},{"title":"resolve.preferAbsolute","id":"resolvepreferabsolute","level":3},{"title":"resolve.symlinks","id":"resolvesymlinks","level":3},{"title":"resolve.cachePredicate","id":"resolvecachepredicate","level":3},{"title":"resolve.restrictions","id":"resolverestrictions","level":3},{"title":"resolve.roots","id":"resolveroots","level":3},{"title":"resolve.importsFields","id":"resolveimportsfields","level":3},{"title":"resolve.byDependency","id":"resolvebydependency","level":3},{"title":"resolveLoader","id":"resolveloader","level":2}],"title":"Resolve","sort":8,"contributors":["sokra","skipjack","SpaceK33z","pksjce","sebastiandeutsch","tbroadley","byzyk","numb86","jgravois","EugeneHlushko","Aghassi","myshov","anikethsaha","chenxsan","jamesgeorge007","snitin315"]},{"path":"src/content/configuration/optimization.mdx","name":"optimization.mdx","size":17660,"type":"file","extension":".mdx","url":"/configuration/optimization/","anchors":[{"title":"optimization.chunkIds","id":"optimizationchunkids","level":2},{"title":"optimization.concatenateModules","id":"optimizationconcatenatemodules","level":2},{"title":"optimization.emitOnErrors","id":"optimizationemitonerrors","level":2},{"title":"optimization.flagIncludedChunks","id":"optimizationflagincludedchunks","level":2},{"title":"optimization.innerGraph","id":"optimizationinnergraph","level":2},{"title":"optimization.mangleExports","id":"optimizationmangleexports","level":2},{"title":"optimization.mangleWasmImports","id":"optimizationmanglewasmimports","level":2},{"title":"optimization.mergeDuplicateChunks","id":"optimizationmergeduplicatechunks","level":2},{"title":"optimization.minimize","id":"optimizationminimize","level":2},{"title":"optimization.minimizer","id":"optimizationminimizer","level":2},{"title":"optimization.moduleIds","id":"optimizationmoduleids","level":2},{"title":"optimization.nodeEnv","id":"optimizationnodeenv","level":2},{"title":"optimization.portableRecords","id":"optimizationportablerecords","level":2},{"title":"optimization.providedExports","id":"optimizationprovidedexports","level":2},{"title":"optimization.realContentHash","id":"optimizationrealcontenthash","level":2},{"title":"optimization.removeAvailableModules","id":"optimizationremoveavailablemodules","level":2},{"title":"optimization.removeEmptyChunks","id":"optimizationremoveemptychunks","level":2},{"title":"optimization.runtimeChunk","id":"optimizationruntimechunk","level":2},{"title":"optimization.sideEffects","id":"optimizationsideeffects","level":2},{"title":"optimization.splitChunks","id":"optimizationsplitchunks","level":2},{"title":"optimization.usedExports","id":"optimizationusedexports","level":2}],"title":"Optimization","sort":9,"contributors":["EugeneHlushko","jeremenichelli","simon04","byzyk","madhavarshney","dhurlburtusa","jamesgeorge007","anikethsaha","snitin315","pixel-ray","chenxsan","Roberto14"],"related":[{"title":"webpack 4: Code Splitting, chunk graph and the splitChunks optimization","url":"https://medium.com/webpack/webpack-4-code-splitting-chunk-graph-and-the-splitchunks-optimization-be739a861366"}]},{"path":"src/content/configuration/plugins.mdx","name":"plugins.mdx","size":1847,"type":"file","extension":".mdx","url":"/configuration/plugins/","anchors":[{"title":"plugins","id":"plugins","level":2}],"title":"Plugins","sort":10,"contributors":["sokra","skipjack","yatharthk","byzyk","EugeneHlushko","snitin315"]},{"path":"src/content/configuration/dev-server.mdx","name":"dev-server.mdx","size":42513,"type":"file","extension":".mdx","url":"/configuration/dev-server/","anchors":[{"title":"devServer","id":"devserver","level":2},{"title":"Usage via CLI","id":"usage-via-cli","level":3},{"title":"Usage via API","id":"usage-via-api","level":3},{"title":"devServer.allowedHosts","id":"devserverallowedhosts","level":2},{"title":"devServer.bonjour","id":"devserverbonjour","level":2},{"title":"devServer.client","id":"devserverclient","level":2},{"title":"logging","id":"logging","level":3},{"title":"overlay","id":"overlay","level":3},{"title":"progress","id":"progress","level":3},{"title":"reconnect","id":"reconnect","level":3},{"title":"webSocketTransport","id":"websockettransport","level":3},{"title":"webSocketURL","id":"websocketurl","level":3},{"title":"devServer.compress","id":"devservercompress","level":2},{"title":"devServer.devMiddleware","id":"devserverdevmiddleware","level":2},{"title":"devServer.http2","id":"devserverhttp2","level":2},{"title":"devServer.https","id":"devserverhttps","level":2},{"title":"devServer.headers","id":"devserverheaders","level":2},{"title":"devServer.historyApiFallback","id":"devserverhistoryapifallback","level":2},{"title":"devServer.host","id":"devserverhost","level":2},{"title":"local-ip","id":"local-ip","level":3},{"title":"local-ipv4","id":"local-ipv4","level":3},{"title":"local-ipv6","id":"local-ipv6","level":3},{"title":"devServer.hot","id":"devserverhot","level":2},{"title":"devServer.ipc","id":"devserveripc","level":2},{"title":"devServer.liveReload","id":"devserverlivereload","level":2},{"title":"devServer.magicHtml","id":"devservermagichtml","level":2},{"title":"devServer.onAfterSetupMiddleware","id":"devserveronaftersetupmiddleware","level":2},{"title":"devServer.onBeforeSetupMiddleware","id":"devserveronbeforesetupmiddleware","level":2},{"title":"devserver.onListening","id":"devserveronlistening","level":2},{"title":"devServer.open","id":"devserveropen","level":2},{"title":"devServer.port","id":"devserverport","level":2},{"title":"devServer.proxy","id":"devserverproxy","level":2},{"title":"devServer.server","id":"devserverserver","level":2},{"title":"devServer.setupExitSignals","id":"devserversetupexitsignals","level":2},{"title":"devServer.setupMiddlewares","id":"devserversetupmiddlewares","level":2},{"title":"devServer.static","id":"devserverstatic","level":2},{"title":"directory","id":"directory","level":3},{"title":"staticOptions","id":"staticoptions","level":3},{"title":"publicPath","id":"publicpath","level":3},{"title":"serveIndex","id":"serveindex","level":3},{"title":"watch","id":"watch","level":3},{"title":"devServer.watchFiles","id":"devserverwatchfiles","level":2},{"title":"devServer.webSocketServer","id":"devserverwebsocketserver","level":2}],"title":"DevServer","sort":11,"contributors":["sokra","skipjack","spacek33z","charlespwd","orteth01","byzyk","EugeneHlushko","Yiidiir","Loonride","dmohns","EslamHiko","digitaljohn","bhavya9107","wizardofhogwarts","jamesgeorge007","g100g","anikethsaha","snitin315","Biki-das","SaulSilver","malcolm-kee"]},{"path":"src/content/configuration/cache.mdx","name":"cache.mdx","size":11908,"type":"file","extension":".mdx","url":"/configuration/cache/","anchors":[{"title":"cache","id":"cache","level":2},{"title":"cache.allowCollectingMemory","id":"cacheallowcollectingmemory","level":3},{"title":"cache.buildDependencies","id":"cachebuilddependencies","level":3},{"title":"cache.cacheDirectory","id":"cachecachedirectory","level":3},{"title":"cache.cacheLocation","id":"cachecachelocation","level":3},{"title":"cache.cacheUnaffected","id":"cachecacheunaffected","level":3},{"title":"cache.compression","id":"cachecompression","level":3},{"title":"cache.hashAlgorithm","id":"cachehashalgorithm","level":3},{"title":"cache.idleTimeout","id":"cacheidletimeout","level":3},{"title":"cache.idleTimeoutAfterLargeChanges","id":"cacheidletimeoutafterlargechanges","level":3},{"title":"cache.idleTimeoutForInitialStore","id":"cacheidletimeoutforinitialstore","level":3},{"title":"cache.managedPaths","id":"cachemanagedpaths","level":3},{"title":"cache.maxAge","id":"cachemaxage","level":3},{"title":"cache.maxGenerations","id":"cachemaxgenerations","level":3},{"title":"cache.maxMemoryGenerations","id":"cachemaxmemorygenerations","level":3},{"title":"cache.memoryCacheUnaffected","id":"cachememorycacheunaffected","level":3},{"title":"cache.name","id":"cachename","level":3},{"title":"cache.profile","id":"cacheprofile","level":3},{"title":"cache.readonly","id":"cachereadonly","level":3},{"title":"cache.store","id":"cachestore","level":3},{"title":"cache.type","id":"cachetype","level":3},{"title":"cache.version","id":"cacheversion","level":3},{"title":"Setup cache in CI/CD system","id":"setup-cache-in-cicd-system","level":2},{"title":"GitLab CI/CD","id":"gitlab-cicd","level":3},{"title":"Github actions","id":"github-actions","level":3}],"title":"Cache","sort":12,"contributors":["snitin315","chenxsan"]},{"path":"src/content/configuration/devtool.mdx","name":"devtool.mdx","size":17292,"type":"file","extension":".mdx","url":"/configuration/devtool/","anchors":[{"title":"devtool","id":"devtool","level":2},{"title":"Qualities","id":"qualities","level":3},{"title":"Development","id":"development","level":3},{"title":"Special cases","id":"special-cases","level":3},{"title":"Production","id":"production","level":3}],"title":"Devtool","sort":12,"contributors":["sokra","skipjack","SpaceK33z","lricoy","madhavarshney","wizardofhogwarts","anikethsaha","snitin315"],"related":[{"title":"Enabling Source Maps","url":"https://survivejs.com/webpack/developing-with-webpack/enabling-sourcemaps/"},{"title":"webpack\'s Devtool Source Map","url":"http://cheng.logdown.com/posts/2016/03/25/679045"}]},{"path":"src/content/configuration/extending-configurations.mdx","name":"extending-configurations.mdx","size":3419,"type":"file","extension":".mdx","url":"/configuration/extending-configurations/","anchors":[{"title":"extends","id":"extends","level":2},{"title":"Extending multiple configurations","id":"extending-multiple-configurations","level":2},{"title":"Overridding Configurations","id":"overridding-configurations","level":2},{"title":"Loading configuration from external packages","id":"loading-configuration-from-external-packages","level":2}],"title":"Extends","sort":12,"contributors":["burhanuday"]},{"path":"src/content/configuration/target.mdx","name":"target.mdx","size":7857,"type":"file","extension":".mdx","url":"/configuration/target/","anchors":[{"title":"target","id":"target","level":2},{"title":"string","id":"string","level":3},{"title":"[string]","id":"string-1","level":3},{"title":"false","id":"false","level":3}],"title":"Target","sort":13,"contributors":["juangl","sokra","skipjack","SpaceK33z","pastelsky","tbroadley","byzyk","EugeneHlushko","smelukov","chenxsan"]},{"path":"src/content/configuration/watch.mdx","name":"watch.mdx","size":6463,"type":"file","extension":".mdx","url":"/configuration/watch/","anchors":[{"title":"watch","id":"watch","level":2},{"title":"watchOptions","id":"watchoptions","level":2},{"title":"watchOptions.aggregateTimeout","id":"watchoptionsaggregatetimeout","level":3},{"title":"watchOptions.ignored","id":"watchoptionsignored","level":3},{"title":"watchOptions.poll","id":"watchoptionspoll","level":3},{"title":"watchOptions.followSymlinks","id":"watchoptionsfollowsymlinks","level":3},{"title":"watchOptions.stdin","id":"watchoptionsstdin","level":3},{"title":"Troubleshooting","id":"troubleshooting","level":2},{"title":"Changes Seen But Not Processed","id":"changes-seen-but-not-processed","level":3},{"title":"Not Enough Watchers","id":"not-enough-watchers","level":3},{"title":"macOS fsevents Bug","id":"macos-fsevents-bug","level":3},{"title":"Windows Paths","id":"windows-paths","level":3},{"title":"Vim","id":"vim","level":3},{"title":"Saving in WebStorm","id":"saving-in-webstorm","level":3}],"title":"Watch and WatchOptions","sort":14,"contributors":["sokra","skipjack","SpaceK33z","EugeneHlushko","byzyk","spicalous","Neob91","Loonride","snitin315","chenxsan"]},{"path":"src/content/configuration/externals.mdx","name":"externals.mdx","size":21244,"type":"file","extension":".mdx","url":"/configuration/externals/","anchors":[{"title":"externals","id":"externals","level":2},{"title":"string","id":"string","level":3},{"title":"[string]","id":"string-1","level":3},{"title":"object","id":"object","level":3},{"title":"function","id":"function","level":3},{"title":"RegExp","id":"regexp","level":3},{"title":"Combining syntaxes","id":"combining-syntaxes","level":3},{"title":"byLayer","id":"bylayer","level":3},{"title":"externalsType","id":"externalstype","level":2},{"title":"externalsType.commonjs","id":"externalstypecommonjs","level":3},{"title":"externalsType.global","id":"externalstypeglobal","level":3},{"title":"externalsType.module","id":"externalstypemodule","level":3},{"title":"externalsType.node-commonjs","id":"externalstypenode-commonjs","level":3},{"title":"externalsType.promise","id":"externalstypepromise","level":3},{"title":"externalsType.self","id":"externalstypeself","level":3},{"title":"externalsType.script","id":"externalstypescript","level":3},{"title":"externalsType.this","id":"externalstypethis","level":3},{"title":"externalsType.var","id":"externalstypevar","level":3},{"title":"externalsType.window","id":"externalstypewindow","level":3},{"title":"externalsPresets","id":"externalspresets","level":2}],"title":"Externals","sort":15,"contributors":["sokra","skipjack","pksjce","fadysamirsadek","byzyk","zefman","Mistyyyy","jamesgeorge007","tanhauhau","snitin315","beejunk","EugeneHlushko","chenxsan","pranshuchittora","kinetifex","anshumanv","SaulSilver"]},{"path":"src/content/configuration/performance.mdx","name":"performance.mdx","size":2639,"type":"file","extension":".mdx","url":"/configuration/performance/","anchors":[{"title":"performance","id":"performance","level":2},{"title":"performance.assetFilter","id":"performanceassetfilter","level":3},{"title":"performance.hints","id":"performancehints","level":3},{"title":"performance.maxAssetSize","id":"performancemaxassetsize","level":3},{"title":"performance.maxEntrypointSize","id":"performancemaxentrypointsize","level":3}],"title":"Performance","sort":16,"contributors":["thelarkinn","tbroadley","byzyk","madhavarshney","EugeneHlushko"]},{"path":"src/content/configuration/node.mdx","name":"node.mdx","size":2484,"type":"file","extension":".mdx","url":"/configuration/node/","anchors":[{"title":"node","id":"node","level":2},{"title":"node.global","id":"nodeglobal","level":2},{"title":"node.__filename","id":"node__filename","level":2},{"title":"node.__dirname","id":"node__dirname","level":2}],"title":"Node","sort":17,"contributors":["sokra","skipjack","oneforwonder","Rob--W","byzyk","EugeneHlushko","anikethsaha","chenxsan"]},{"path":"src/content/configuration/stats.mdx","name":"stats.mdx","size":23173,"type":"file","extension":".mdx","url":"/configuration/stats/","anchors":[{"title":"Stats Presets","id":"stats-presets","level":2},{"title":"Stats Options","id":"stats-options","level":2},{"title":"stats.all","id":"statsall","level":3},{"title":"stats.assets","id":"statsassets","level":3},{"title":"stats.assetsSort","id":"statsassetssort","level":3},{"title":"stats.builtAt","id":"statsbuiltat","level":3},{"title":"stats.moduleAssets","id":"statsmoduleassets","level":3},{"title":"stats.assetsSpace","id":"statsassetsspace","level":3},{"title":"stats.modulesSpace","id":"statsmodulesspace","level":3},{"title":"stats.chunkModulesSpace","id":"statschunkmodulesspace","level":3},{"title":"stats.nestedModules","id":"statsnestedmodules","level":3},{"title":"stats.nestedModulesSpace","id":"statsnestedmodulesspace","level":3},{"title":"stats.cached","id":"statscached","level":3},{"title":"stats.cachedModules","id":"statscachedmodules","level":3},{"title":"stats.runtimeModules","id":"statsruntimemodules","level":3},{"title":"stats.dependentModules","id":"statsdependentmodules","level":3},{"title":"stats.groupAssetsByChunk","id":"statsgroupassetsbychunk","level":3},{"title":"stats.groupAssetsByEmitStatus","id":"statsgroupassetsbyemitstatus","level":3},{"title":"stats.groupAssetsByExtension","id":"statsgroupassetsbyextension","level":3},{"title":"stats.groupAssetsByInfo","id":"statsgroupassetsbyinfo","level":3},{"title":"stats.groupAssetsByPath","id":"statsgroupassetsbypath","level":3},{"title":"stats.groupModulesByAttributes","id":"statsgroupmodulesbyattributes","level":3},{"title":"stats.groupModulesByCacheStatus","id":"statsgroupmodulesbycachestatus","level":3},{"title":"stats.groupModulesByExtension","id":"statsgroupmodulesbyextension","level":3},{"title":"stats.groupModulesByLayer","id":"statsgroupmodulesbylayer","level":3},{"title":"stats.groupModulesByPath","id":"statsgroupmodulesbypath","level":3},{"title":"stats.groupModulesByType","id":"statsgroupmodulesbytype","level":3},{"title":"stats.groupReasonsByOrigin","id":"statsgroupreasonsbyorigin","level":3},{"title":"stats.cachedAssets","id":"statscachedassets","level":3},{"title":"stats.children","id":"statschildren","level":3},{"title":"stats.chunks","id":"statschunks","level":3},{"title":"stats.chunkGroups","id":"statschunkgroups","level":3},{"title":"stats.chunkModules","id":"statschunkmodules","level":3},{"title":"stats.chunkOrigins","id":"statschunkorigins","level":3},{"title":"stats.chunksSort","id":"statschunkssort","level":3},{"title":"stats.context","id":"statscontext","level":3},{"title":"stats.colors","id":"statscolors","level":3},{"title":"stats.depth","id":"statsdepth","level":3},{"title":"stats.entrypoints","id":"statsentrypoints","level":3},{"title":"stats.env","id":"statsenv","level":3},{"title":"stats.orphanModules","id":"statsorphanmodules","level":3},{"title":"stats.errors","id":"statserrors","level":3},{"title":"stats.errorDetails","id":"statserrordetails","level":3},{"title":"stats.errorStack","id":"statserrorstack","level":3},{"title":"stats.errorsSpace","id":"statserrorsspace","level":3},{"title":"stats.excludeAssets","id":"statsexcludeassets","level":3},{"title":"stats.excludeModules","id":"statsexcludemodules","level":3},{"title":"stats.exclude","id":"statsexclude","level":3},{"title":"stats.hash","id":"statshash","level":3},{"title":"stats.logging","id":"statslogging","level":3},{"title":"stats.loggingDebug","id":"statsloggingdebug","level":3},{"title":"stats.loggingTrace","id":"statsloggingtrace","level":3},{"title":"stats.modules","id":"statsmodules","level":3},{"title":"stats.modulesSort","id":"statsmodulessort","level":3},{"title":"stats.moduleTrace","id":"statsmoduletrace","level":3},{"title":"stats.optimizationBailout","id":"statsoptimizationbailout","level":3},{"title":"stats.outputPath","id":"statsoutputpath","level":3},{"title":"stats.performance","id":"statsperformance","level":3},{"title":"stats.preset","id":"statspreset","level":3},{"title":"stats.providedExports","id":"statsprovidedexports","level":3},{"title":"stats.errorsCount","id":"statserrorscount","level":3},{"title":"stats.warningsCount","id":"statswarningscount","level":3},{"title":"stats.publicPath","id":"statspublicpath","level":3},{"title":"stats.reasons","id":"statsreasons","level":3},{"title":"stats.reasonsSpace","id":"statsreasonsspace","level":3},{"title":"stats.relatedAssets","id":"statsrelatedassets","level":3},{"title":"stats.source","id":"statssource","level":3},{"title":"stats.timings","id":"statstimings","level":3},{"title":"stats.ids","id":"statsids","level":3},{"title":"stats.usedExports","id":"statsusedexports","level":3},{"title":"stats.version","id":"statsversion","level":3},{"title":"stats.chunkGroupAuxiliary","id":"statschunkgroupauxiliary","level":3},{"title":"stats.chunkGroupChildren","id":"statschunkgroupchildren","level":3},{"title":"stats.chunkGroupMaxAssets","id":"statschunkgroupmaxassets","level":3},{"title":"stats.warnings","id":"statswarnings","level":3},{"title":"stats.warningsSpace","id":"statswarningsspace","level":3},{"title":"stats.warningsFilter","id":"statswarningsfilter","level":3},{"title":"stats.chunkRelations","id":"statschunkrelations","level":3},{"title":"Sorting fields","id":"sorting-fields","level":3},{"title":"Extending stats behaviours","id":"extending-stats-behaviours","level":3}],"title":"Stats","sort":18,"contributors":["SpaceK33z","sallar","jungomi","ldrick","jasonblanchard","byzyk","renjithspace","Raiondesu","EugeneHlushko","grgur","anshumanv","pixel-ray","snitin315","u01jmg3","grrizzly"]},{"path":"src/content/configuration/experiments.mdx","name":"experiments.mdx","size":9572,"type":"file","extension":".mdx","url":"/configuration/experiments/","anchors":[{"title":"experiments","id":"experiments","level":2},{"title":"experiments.backCompat","id":"experimentsbackcompat","level":3},{"title":"experiments.buildHttp","id":"experimentsbuildhttp","level":3},{"title":"experiments.css","id":"experimentscss","level":3},{"title":"experiments.cacheUnaffected","id":"experimentscacheunaffected","level":3},{"title":"experiments.futureDefaults","id":"experimentsfuturedefaults","level":3},{"title":"experiments.lazyCompilation","id":"experimentslazycompilation","level":3},{"title":"experiments.outputModule","id":"experimentsoutputmodule","level":3},{"title":"experiments.topLevelAwait","id":"experimentstoplevelawait","level":3}],"title":"Experiments","sort":19,"contributors":["EugeneHlushko","wizardofhogwarts","chenxsan","anshumanv","snitin315","burhanuday"]},{"path":"src/content/configuration/other-options.mdx","name":"other-options.mdx","size":13286,"type":"file","extension":".mdx","url":"/configuration/other-options/","anchors":[{"title":"amd","id":"amd","level":2},{"title":"bail","id":"bail","level":2},{"title":"dependencies","id":"dependencies","level":2},{"title":"ignoreWarnings","id":"ignorewarnings","level":2},{"title":"infrastructureLogging","id":"infrastructurelogging","level":2},{"title":"appendOnly","id":"appendonly","level":3},{"title":"colors","id":"colors","level":3},{"title":"console","id":"console","level":3},{"title":"debug","id":"debug","level":3},{"title":"level","id":"level","level":3},{"title":"stream","id":"stream","level":3},{"title":"loader","id":"loader","level":2},{"title":"name","id":"name","level":2},{"title":"parallelism","id":"parallelism","level":2},{"title":"profile","id":"profile","level":2},{"title":"recordsInputPath","id":"recordsinputpath","level":2},{"title":"recordsOutputPath","id":"recordsoutputpath","level":2},{"title":"recordsPath","id":"recordspath","level":2},{"title":"snapshot","id":"snapshot","level":2},{"title":"buildDependencies","id":"builddependencies","level":3},{"title":"immutablePaths","id":"immutablepaths","level":3},{"title":"managedPaths","id":"managedpaths","level":3},{"title":"module","id":"module","level":3},{"title":"resolve","id":"resolve","level":3},{"title":"resolveBuildDependencies","id":"resolvebuilddependencies","level":3}],"title":"Other Options","sort":20,"contributors":["sokra","skipjack","terinjokes","byzyk","liorgreenb","vansosnin","EugeneHlushko","skovy","rishabh3112","niravasher","Neob91","chenxsan","u01jmg3","jamesgeorge007","snitin315"],"related":[{"title":"Using Records","url":"https://survivejs.com/webpack/optimizing/separating-manifest/#using-records"}]}],"size":327529,"type":"directory","url":"/configuration/"},{"path":"src/content/contribute","name":"contribute","children":[{"path":"src/content/contribute/index.mdx","name":"index.mdx","size":4703,"type":"file","extension":".mdx","url":"/contribute/","anchors":[{"title":"Developers","id":"developers","level":2},{"title":"How Can I Help?","id":"how-can-i-help","level":3},{"title":"Encouraging Employers","id":"encouraging-employers","level":3},{"title":"Your Contributions","id":"your-contributions","level":3},{"title":"Executives","id":"executives","level":2},{"title":"Sponsorship","id":"sponsorship","level":3},{"title":"Anyone Else","id":"anyone-else","level":3},{"title":"Pull requests","id":"pull-requests","level":2}],"title":"Contribute","sort":-1,"contributors":["rouzbeh84","scottdj92","harrynewsome","dhedgecock","tbroadley","EugeneHlushko","dkdk225"]},{"path":"src/content/contribute/writers-guide.mdx","name":"writers-guide.mdx","size":6883,"type":"file","extension":".mdx","url":"/contribute/writers-guide/","anchors":[{"title":"Process","id":"process","level":2},{"title":"YAML Frontmatter","id":"yaml-frontmatter","level":2},{"title":"Article Structure","id":"article-structure","level":2},{"title":"Typesetting","id":"typesetting","level":2},{"title":"Formatting","id":"formatting","level":2},{"title":"Code","id":"code","level":3},{"title":"Lists","id":"lists","level":3},{"title":"Tables","id":"tables","level":3},{"title":"Configuration Properties","id":"configuration-properties","level":3},{"title":"Quotes","id":"quotes","level":3},{"title":"Assumptions and simplicity","id":"assumptions-and-simplicity","level":3},{"title":"Configuration defaults and types","id":"configuration-defaults-and-types","level":3},{"title":"Options shortlists and their typing","id":"options-shortlists-and-their-typing","level":3},{"title":"Adding links","id":"adding-links","level":3}],"title":"Writer\'s Guide","sort":1,"contributors":["pranshuchittora","EugeneHlushko"]},{"path":"src/content/contribute/writing-a-loader.mdx","name":"writing-a-loader.mdx","size":13545,"type":"file","extension":".mdx","url":"/contribute/writing-a-loader/","anchors":[{"title":"Setup","id":"setup","level":2},{"title":"Simple Usage","id":"simple-usage","level":2},{"title":"Complex Usage","id":"complex-usage","level":2},{"title":"Guidelines","id":"guidelines","level":2},{"title":"Simple","id":"simple","level":3},{"title":"Chaining","id":"chaining","level":3},{"title":"Modular","id":"modular","level":3},{"title":"Stateless","id":"stateless","level":3},{"title":"Loader Utilities","id":"loader-utilities","level":3},{"title":"Loader Dependencies","id":"loader-dependencies","level":3},{"title":"Module Dependencies","id":"module-dependencies","level":3},{"title":"Common Code","id":"common-code","level":3},{"title":"Absolute Paths","id":"absolute-paths","level":3},{"title":"Peer Dependencies","id":"peer-dependencies","level":3},{"title":"Testing","id":"testing","level":2}],"title":"Writing a Loader","sort":2,"contributors":["asulaiman","michael-ciniawsky","byzyk","anikethsaha","jamesgeorge007","chenxsan","dev-itsheng"]},{"path":"src/content/contribute/writing-a-plugin.mdx","name":"writing-a-plugin.mdx","size":13637,"type":"file","extension":".mdx","url":"/contribute/writing-a-plugin/","anchors":[{"title":"Creating a Plugin","id":"creating-a-plugin","level":2},{"title":"Basic plugin architecture","id":"basic-plugin-architecture","level":2},{"title":"Compiler and Compilation","id":"compiler-and-compilation","level":2},{"title":"Async event hooks","id":"async-event-hooks","level":2},{"title":"tapAsync","id":"tapasync","level":3},{"title":"Example","id":"example","level":2},{"title":"Different Plugin Shapes","id":"different-plugin-shapes","level":2},{"title":"Synchronous Hooks","id":"synchronous-hooks","level":3},{"title":"Asynchronous Hooks","id":"asynchronous-hooks","level":3},{"title":"Configuration defaults","id":"configuration-defaults","level":3}],"title":"Writing a Plugin","sort":3,"contributors":["slavafomin","tbroadley","nveenjain","iamakulov","byzyk","franjohn21","EugeneHlushko","snitin315","rahul3v","jamesgeorge007"]},{"path":"src/content/contribute/plugin-patterns.mdx","name":"plugin-patterns.mdx","size":4742,"type":"file","extension":".mdx","url":"/contribute/plugin-patterns/","anchors":[{"title":"Exploring assets, chunks, modules, and dependencies","id":"exploring-assets-chunks-modules-and-dependencies","level":2},{"title":"Monitoring the watch graph","id":"monitoring-the-watch-graph","level":3},{"title":"Changed chunks","id":"changed-chunks","level":2}],"title":"Plugin Patterns","sort":5,"contributors":["nveenjain","EugeneHlushko","benglynn"]},{"path":"src/content/contribute/release-process.mdx","name":"release-process.mdx","size":831,"type":"file","extension":".mdx","url":"/contribute/release-process/","anchors":[{"title":"Pull Requests","id":"pull-requests","level":2},{"title":"Releasing","id":"releasing","level":2}],"title":"Release Process","sort":6,"contributors":["d3viant0ne","sokra","byzyk","chenxsan"]},{"path":"src/content/contribute/debugging.mdx","name":"debugging.mdx","size":3576,"type":"file","extension":".mdx","url":"/contribute/debugging/","anchors":[{"title":"Stats","id":"stats","level":2},{"title":"DevTools","id":"devtools","level":2}],"title":"Debugging","sort":7,"contributors":["skipjack","tbroadley","madhavarshney","bhavya9107","akaustav"],"related":[{"title":"Learn and Debug webpack with Chrome DevTools!","url":"https://medium.com/webpack/webpack-bits-learn-and-debug-webpack-with-chrome-dev-tools-da1c5b19554"},{"title":"Debugging Guide | Node","url":"https://nodejs.org/en/docs/guides/debugging-getting-started/"},{"title":"Debugging Node.js with Chrome DevTools","url":"https://medium.com/@paul_irish/debugging-node-js-nightlies-with-chrome-devtools-7c4a1b95ae27"}]}],"size":47917,"type":"directory","url":"/contribute/"},{"path":"src/content/guides","name":"guides","children":[{"path":"src/content/guides/index.mdx","name":"index.mdx","size":924,"type":"file","extension":".mdx","url":"/guides/","anchors":[],"title":"Guides","sort":-1,"contributors":["skipjack","EugeneHlushko","benschac"]},{"path":"src/content/guides/getting-started.mdx","name":"getting-started.mdx","size":12838,"type":"file","extension":".mdx","url":"/guides/getting-started/","anchors":[{"title":"Basic Setup","id":"basic-setup","level":2},{"title":"Creating a Bundle","id":"creating-a-bundle","level":2},{"title":"Modules","id":"modules","level":2},{"title":"Using a Configuration","id":"using-a-configuration","level":2},{"title":"NPM Scripts","id":"npm-scripts","level":2},{"title":"Conclusion","id":"conclusion","level":2}],"title":"Getting Started","description":"Learn how to bundle a JavaScript application with webpack 5.","sort":1,"contributors":["bebraw","varunjayaraman","cntanglijun","chrisVillanueva","johnstew","simon04","aaronang","TheDutchCoder","sudarsangp","Vanguard90","chenxsan","EugeneHlushko","ATGardner","ayvarot","bjarki","ztomasze","Spiral90210","byzyk","wizardofhogwarts","myshov","anshumanv","d3lm","snitin315","Etheryen"]},{"path":"src/content/guides/asset-management.mdx","name":"asset-management.mdx","size":24303,"type":"file","extension":".mdx","url":"/guides/asset-management/","anchors":[{"title":"Setup","id":"setup","level":2},{"title":"Loading CSS","id":"loading-css","level":2},{"title":"Loading Images","id":"loading-images","level":2},{"title":"Loading Fonts","id":"loading-fonts","level":2},{"title":"Loading Data","id":"loading-data","level":2},{"title":"Customize parser of JSON modules","id":"customize-parser-of-json-modules","level":3},{"title":"Global Assets","id":"global-assets","level":2},{"title":"Wrapping up","id":"wrapping-up","level":2},{"title":"Next guide","id":"next-guide","level":2},{"title":"Further Reading","id":"further-reading","level":2}],"title":"Asset Management","sort":2,"contributors":["skipjack","michael-ciniawsky","TheDutchCoder","sudarsangp","chenxsan","EugeneHlushko","AnayaDesign","wizardofhogwarts","astonizer","snitin315"]},{"path":"src/content/guides/output-management.mdx","name":"output-management.mdx","size":7573,"type":"file","extension":".mdx","url":"/guides/output-management/","anchors":[{"title":"Preparation","id":"preparation","level":2},{"title":"Setting up HtmlWebpackPlugin","id":"setting-up-htmlwebpackplugin","level":2},{"title":"Cleaning up the /dist folder","id":"cleaning-up-the-dist-folder","level":2},{"title":"The Manifest","id":"the-manifest","level":2},{"title":"Conclusion","id":"conclusion","level":2}],"title":"Output Management","sort":3,"contributors":["skipjack","TheDutchCoder","sudarsangp","JGJP","EugeneHlushko","AnayaDesign","chenxsan","snitin315"]},{"path":"src/content/guides/development.mdx","name":"development.mdx","size":14559,"type":"file","extension":".mdx","url":"/guides/development/","anchors":[{"title":"Using source maps","id":"using-source-maps","level":2},{"title":"Choosing a Development Tool","id":"choosing-a-development-tool","level":2},{"title":"Using Watch Mode","id":"using-watch-mode","level":3},{"title":"Using webpack-dev-server","id":"using-webpack-dev-server","level":3},{"title":"Using webpack-dev-middleware","id":"using-webpack-dev-middleware","level":3},{"title":"Adjusting Your Text Editor","id":"adjusting-your-text-editor","level":2},{"title":"Conclusion","id":"conclusion","level":2}],"title":"Development","sort":4,"contributors":["SpaceK33z","rafde","fvgs","TheDutchCoder","WojciechKo","Calinou","GAumala","EugeneHlushko","byzyk","trivikr","aholzner","chenxsan","maxloh","snitin315","f3ndot"]},{"path":"src/content/guides/code-splitting.mdx","name":"code-splitting.mdx","size":18088,"type":"file","extension":".mdx","url":"/guides/code-splitting/","anchors":[{"title":"Entry Points","id":"entry-points","level":2},{"title":"Prevent Duplication","id":"prevent-duplication","level":2},{"title":"Entry dependencies","id":"entry-dependencies","level":3},{"title":"SplitChunksPlugin","id":"splitchunksplugin","level":3},{"title":"Dynamic Imports","id":"dynamic-imports","level":2},{"title":"Prefetching/Preloading modules","id":"prefetchingpreloading-modules","level":2},{"title":"Bundle Analysis","id":"bundle-analysis","level":2},{"title":"Next Steps","id":"next-steps","level":2}],"title":"Code Splitting","sort":5,"contributors":["pksjce","pastelsky","simon04","jonwheeler","johnstew","shinxi","tomtasche","levy9527","rahulcs","chrisVillanueva","rafde","bartushek","shaunwallace","skipjack","jakearchibald","TheDutchCoder","rouzbeh84","shaodahong","sudarsangp","kcolton","efreitasn","EugeneHlushko","Tiendo1011","byzyk","AnayaDesign","wizardofhogwarts","maximilianschmelzer","smelukov","chenxsan","Adarah","atesgoral","snitin315","artem-malko"],"related":[{"title":" in webpack","url":"https://medium.com/webpack/link-rel-prefetch-preload-in-webpack-51a52358f84c"},{"title":"Preload, Prefetch And Priorities in Chrome","url":"https://medium.com/reloading/preload-prefetch-and-priorities-in-chrome-776165961bbf"},{"title":"Preloading content with ","url":"https://developer.mozilla.org/en-US/docs/Web/HTML/Preloading_content"}]},{"path":"src/content/guides/caching.mdx","name":"caching.mdx","size":11422,"type":"file","extension":".mdx","url":"/guides/caching/","anchors":[{"title":"Output Filenames","id":"output-filenames","level":2},{"title":"Extracting Boilerplate","id":"extracting-boilerplate","level":2},{"title":"Module Identifiers","id":"module-identifiers","level":2},{"title":"Conclusion","id":"conclusion","level":2}],"title":"Caching","sort":6,"contributors":["okonet","jouni-kantola","skipjack","dannycjones","fadysamirsadek","afontcu","rosavage","saiprasad2595","EugeneHlushko","AnayaDesign","aholzner","snitin315"],"related":[{"title":"Issue 652","url":"https://github.com/webpack/webpack.js.org/issues/652"}]},{"path":"src/content/guides/author-libraries.mdx","name":"author-libraries.mdx","size":8163,"type":"file","extension":".mdx","url":"/guides/author-libraries/","anchors":[{"title":"Authoring a Library","id":"authoring-a-library","level":2},{"title":"Webpack Configuration","id":"webpack-configuration","level":2},{"title":"Expose the Library","id":"expose-the-library","level":2},{"title":"Externalize Lodash","id":"externalize-lodash","level":2},{"title":"External Limitations","id":"external-limitations","level":3},{"title":"Final Steps","id":"final-steps","level":2}],"title":"Authoring Libraries","sort":7,"contributors":["pksjce","johnstew","simon04","5angel","marioacc","byzyk","EugeneHlushko","AnayaDesign","chenxsan","wizardofhogwarts"]},{"path":"src/content/guides/environment-variables.mdx","name":"environment-variables.mdx","size":1845,"type":"file","extension":".mdx","url":"/guides/environment-variables/","anchors":[],"title":"Environment Variables","sort":8,"contributors":["simon04","grisanu","tbroadley","legalcodes","byzyk","jceipek","snitin315"]},{"path":"src/content/guides/build-performance.mdx","name":"build-performance.mdx","size":8685,"type":"file","extension":".mdx","url":"/guides/build-performance/","anchors":[{"title":"General","id":"general","level":2},{"title":"Stay Up to Date","id":"stay-up-to-date","level":3},{"title":"Loaders","id":"loaders","level":3},{"title":"Bootstrap","id":"bootstrap","level":3},{"title":"Resolving","id":"resolving","level":3},{"title":"Dlls","id":"dlls","level":3},{"title":"Smaller = Faster","id":"smaller--faster","level":3},{"title":"Worker Pool","id":"worker-pool","level":3},{"title":"Persistent cache","id":"persistent-cache","level":3},{"title":"Custom plugins/loaders","id":"custom-pluginsloaders","level":3},{"title":"Progress plugin","id":"progress-plugin","level":3},{"title":"Development","id":"development","level":2},{"title":"Incremental Builds","id":"incremental-builds","level":3},{"title":"Compile in Memory","id":"compile-in-memory","level":3},{"title":"stats.toJson speed","id":"statstojson-speed","level":3},{"title":"Devtool","id":"devtool","level":3},{"title":"Avoid Production Specific Tooling","id":"avoid-production-specific-tooling","level":3},{"title":"Minimal Entry Chunk","id":"minimal-entry-chunk","level":3},{"title":"Avoid Extra Optimization Steps","id":"avoid-extra-optimization-steps","level":3},{"title":"Output Without Path Info","id":"output-without-path-info","level":3},{"title":"Node.js Versions 8.9.10-9.11.1","id":"nodejs-versions-8910-9111","level":3},{"title":"TypeScript Loader","id":"typescript-loader","level":3},{"title":"Production","id":"production","level":2},{"title":"Source Maps","id":"source-maps","level":3},{"title":"Specific Tooling Issues","id":"specific-tooling-issues","level":2},{"title":"Babel","id":"babel","level":3},{"title":"TypeScript","id":"typescript","level":3},{"title":"Sass","id":"sass","level":3}],"title":"Build Performance","sort":9,"contributors":["sokra","tbroadley","byzyk","madhavarshney","wizardofhogwarts","anikethsaha"]},{"path":"src/content/guides/csp.mdx","name":"csp.mdx","size":2291,"type":"file","extension":".mdx","url":"/guides/csp/","anchors":[{"title":"Examples","id":"examples","level":2},{"title":"Enabling CSP","id":"enabling-csp","level":2},{"title":"Trusted Types","id":"trusted-types","level":2}],"title":"Content Security Policies","sort":10,"contributors":["EugeneHlushko","probablyup","wizardofhogwarts","koto"],"related":[{"title":"Nonce purpose explained","url":"https://stackoverflow.com/questions/42922784/what-s-the-purpose-of-the-html-nonce-attribute-for-script-and-style-elements"},{"title":"On the Insecurity of Whitelists and the Future of Content Security Policy","url":"https://ai.google/research/pubs/pub45542"},{"title":"Locking Down Your Website Scripts with CSP, Hashes, Nonces and Report URI","url":"https://www.troyhunt.com/locking-down-your-website-scripts-with-csp-hashes-nonces-and-report-uri/"},{"title":"CSP on MDN","url":"https://developer.mozilla.org/en-US/docs/Web/HTTP/CSP"},{"title":"Trusted Types","url":"https://web.dev/trusted-types"}]},{"path":"src/content/guides/development-vagrant.mdx","name":"development-vagrant.mdx","size":3484,"type":"file","extension":".mdx","url":"/guides/development-vagrant/","anchors":[{"title":"Configuring the Project","id":"configuring-the-project","level":2},{"title":"Running the Server","id":"running-the-server","level":2},{"title":"Advanced Usage with nginx","id":"advanced-usage-with-nginx","level":2},{"title":"Conclusion","id":"conclusion","level":2}],"title":"Development - Vagrant","sort":11,"contributors":["SpaceK33z","chrisVillanueva","byzyk","wizardofhogwarts"]},{"path":"src/content/guides/dependency-management.mdx","name":"dependency-management.mdx","size":3159,"type":"file","extension":".mdx","url":"/guides/dependency-management/","anchors":[{"title":"require with expression","id":"require-with-expression","level":2},{"title":"require.context","id":"requirecontext","level":2},{"title":"context module API","id":"context-module-api","level":3}],"title":"Dependency Management","sort":12,"contributors":["ndelangen","chrisVillanueva","sokra","byzyk","AnayaDesign"]},{"path":"src/content/guides/installation.mdx","name":"installation.mdx","size":2799,"type":"file","extension":".mdx","url":"/guides/installation/","anchors":[{"title":"Prerequisites","id":"prerequisites","level":2},{"title":"Local Installation","id":"local-installation","level":2},{"title":"Global Installation","id":"global-installation","level":2},{"title":"Bleeding Edge","id":"bleeding-edge","level":2}],"title":"Installation","sort":13,"contributors":["pksjce","bebraw","simon04","EugeneHlushko","sibiraj-s","chenxsan"]},{"path":"src/content/guides/hot-module-replacement.mdx","name":"hot-module-replacement.mdx","size":12146,"type":"file","extension":".mdx","url":"/guides/hot-module-replacement/","anchors":[{"title":"Enabling HMR","id":"enabling-hmr","level":2},{"title":"Via the Node.js API","id":"via-the-nodejs-api","level":2},{"title":"Gotchas","id":"gotchas","level":2},{"title":"HMR with Stylesheets","id":"hmr-with-stylesheets","level":2},{"title":"Other Code and Frameworks","id":"other-code-and-frameworks","level":2}],"title":"Hot Module Replacement","sort":15,"contributors":["jmreidy","jhnns","sararubin","rohannair","joshsantos","drpicox","skipjack","sbaidon","gdi2290","bdwain","caryli","xgirma","EugeneHlushko","AnayaDesign","aviyacohen","dhruvdutt","wizardofhogwarts","aholzner","snitin315"],"related":[{"title":"Concepts - Hot Module Replacement","url":"/concepts/hot-module-replacement"},{"title":"API - Hot Module Replacement","url":"/api/hot-module-replacement"}]},{"path":"src/content/guides/tree-shaking.mdx","name":"tree-shaking.mdx","size":15044,"type":"file","extension":".mdx","url":"/guides/tree-shaking/","anchors":[{"title":"Add a Utility","id":"add-a-utility","level":2},{"title":"Mark the file as side-effect-free","id":"mark-the-file-as-side-effect-free","level":2},{"title":"Clarifying tree shaking and sideEffects","id":"clarifying-tree-shaking-and-sideeffects","level":2},{"title":"Mark a function call as side-effect-free","id":"mark-a-function-call-as-side-effect-free","level":2},{"title":"Minify the Output","id":"minify-the-output","level":2},{"title":"Conclusion","id":"conclusion","level":2}],"title":"Tree Shaking","sort":16,"contributors":["simon04","zacanger","alexjoverm","avant1","MijaelWatts","dmitriid","probablyup","gish","lumo10","byzyk","pnevares","EugeneHlushko","AnayaDesign","torifat","rahul3v","snitin315"],"related":[{"title":"Debugging Optimization Bailouts","url":"https://webpack.js.org/plugins/module-concatenation-plugin/#debugging-optimization-bailouts"},{"title":"Issue 6074 - Add support for more complex selectors for sideEffects","url":"https://github.com/webpack/webpack/issues/6074"}]},{"path":"src/content/guides/production.mdx","name":"production.mdx","size":9195,"type":"file","extension":".mdx","url":"/guides/production/","anchors":[{"title":"Setup","id":"setup","level":2},{"title":"NPM Scripts","id":"npm-scripts","level":2},{"title":"Specify the Mode","id":"specify-the-mode","level":2},{"title":"Minification","id":"minification","level":2},{"title":"Source Mapping","id":"source-mapping","level":2},{"title":"Minimize CSS","id":"minimize-css","level":2},{"title":"CLI Alternatives","id":"cli-alternatives","level":2}],"title":"Production","sort":17,"contributors":["henriquea","rajagopal4890","makuzaverite","markerikson","simon04","kisnows","chrisVillanueva","swapnilmishra","bring2dip","redian","skipjack","xgqfrms","kelset","xgirma","mehrdaad","SevenOutman","AnayaDesign","wizardofhogwarts","aholzner","EugeneHlushko","snitin315"]},{"path":"src/content/guides/lazy-loading.mdx","name":"lazy-loading.mdx","size":4299,"type":"file","extension":".mdx","url":"/guides/lazy-loading/","anchors":[{"title":"Example","id":"example","level":2},{"title":"Frameworks","id":"frameworks","level":2}],"title":"Lazy Loading","sort":18,"contributors":["iammerrick","chrisVillanueva","skipjack","byzyk","EugeneHlushko","AnayaDesign","tapanprakasht","snitin315"],"related":[{"title":"Lazy Loading ES2015 Modules in the Browser","url":"https://dzone.com/articles/lazy-loading-es2015-modules-in-the-browser"},{"title":"Asynchronous vs Deferred JavaScript","url":"https://bitsofco.de/async-vs-defer/"}]},{"path":"src/content/guides/ecma-script-modules.mdx","name":"ecma-script-modules.mdx","size":3017,"type":"file","extension":".mdx","url":"/guides/ecma-script-modules/","anchors":[{"title":"Exporting","id":"exporting","level":2},{"title":"Importing","id":"importing","level":2},{"title":"Flagging modules as ESM","id":"flagging-modules-as-esm","level":2}],"title":"ECMAScript Modules","sort":19,"contributors":["sokra"],"related":[{"title":"ECMAScript Modules in Node.js","url":"https://nodejs.org/api/esm.html"}]},{"path":"src/content/guides/shimming.mdx","name":"shimming.mdx","size":14898,"type":"file","extension":".mdx","url":"/guides/shimming/","anchors":[{"title":"Shimming Globals","id":"shimming-globals","level":2},{"title":"Granular Shimming","id":"granular-shimming","level":2},{"title":"Global Exports","id":"global-exports","level":2},{"title":"Loading Polyfills","id":"loading-polyfills","level":2},{"title":"Further Optimizations","id":"further-optimizations","level":2},{"title":"Node Built-Ins","id":"node-built-ins","level":2},{"title":"Other Utilities","id":"other-utilities","level":2}],"title":"Shimming","sort":20,"contributors":["pksjce","jhnns","simon04","jeremenichelli","svyandun","byzyk","EugeneHlushko","AnayaDesign","dhurlburtusa","plr108","NicolasLetellier","wizardofhogwarts","snitin315","chenxsan"],"related":[{"title":"Reward modern browser users script","url":"https://medium.com/hackernoon/10-things-i-learned-making-the-fastest-site-in-the-world-18a0e1cdf4a7"},{"title":"useBuiltIns in babel-preset-env","url":"https://babeljs.io/docs/en/babel-preset-env#usebuiltins"}]},{"path":"src/content/guides/typescript.mdx","name":"typescript.mdx","size":6914,"type":"file","extension":".mdx","url":"/guides/typescript/","anchors":[{"title":"Basic Setup","id":"basic-setup","level":2},{"title":"Loader","id":"loader","level":2},{"title":"Source Maps","id":"source-maps","level":2},{"title":"Client types","id":"client-types","level":2},{"title":"Using Third Party Libraries","id":"using-third-party-libraries","level":2},{"title":"Importing Other Assets","id":"importing-other-assets","level":2},{"title":"Build Performance","id":"build-performance","level":2}],"title":"TypeScript","sort":21,"contributors":["morsdyce","kkamali","mtrivera","byzyk","EugeneHlushko","chenxsan","snitin315"]},{"path":"src/content/guides/web-workers.mdx","name":"web-workers.mdx","size":2026,"type":"file","extension":".mdx","url":"/guides/web-workers/","anchors":[{"title":"Syntax","id":"syntax","level":2},{"title":"Example","id":"example","level":2},{"title":"Node.js","id":"nodejs","level":2}],"title":"Web Workers","sort":21,"contributors":["chenxsan"]},{"path":"src/content/guides/progressive-web-application.mdx","name":"progressive-web-application.mdx","size":6018,"type":"file","extension":".mdx","url":"/guides/progressive-web-application/","anchors":[{"title":"We Don\'t Work Offline Now","id":"we-dont-work-offline-now","level":2},{"title":"Adding Workbox","id":"adding-workbox","level":2},{"title":"Registering Our Service Worker","id":"registering-our-service-worker","level":2},{"title":"Conclusion","id":"conclusion","level":2}],"title":"Progressive Web Application","sort":22,"contributors":["johnnyreilly","chenxsan","EugeneHlushko","benschac","aholzner"]},{"path":"src/content/guides/public-path.mdx","name":"public-path.mdx","size":3070,"type":"file","extension":".mdx","url":"/guides/public-path/","anchors":[{"title":"Use Cases","id":"use-cases","level":2},{"title":"Environment Based","id":"environment-based","level":3},{"title":"On The Fly","id":"on-the-fly","level":3},{"title":"Automatic publicPath","id":"automatic-publicpath","level":3}],"title":"Public Path","sort":23,"contributors":["rafaelrinaldi","chrisVillanueva","gonzoyumo","chenxsan"]},{"path":"src/content/guides/integrations.mdx","name":"integrations.mdx","size":5414,"type":"file","extension":".mdx","url":"/guides/integrations/","anchors":[{"title":"NPM Scripts","id":"npm-scripts","level":2},{"title":"Grunt","id":"grunt","level":2},{"title":"Gulp","id":"gulp","level":2},{"title":"Mocha","id":"mocha","level":2},{"title":"Karma","id":"karma","level":2}],"title":"Integrations","sort":24,"contributors":["pksjce","bebraw","tashian","skipjack","AnayaDesign"]},{"path":"src/content/guides/asset-modules.mdx","name":"asset-modules.mdx","size":11519,"type":"file","extension":".mdx","url":"/guides/asset-modules/","anchors":[{"title":"Resource assets","id":"resource-assets","level":2},{"title":"Custom output filename","id":"custom-output-filename","level":3},{"title":"Inlining assets","id":"inlining-assets","level":2},{"title":"Custom data URI generator","id":"custom-data-uri-generator","level":3},{"title":"Source assets","id":"source-assets","level":2},{"title":"URL assets","id":"url-assets","level":2},{"title":"General asset type","id":"general-asset-type","level":2},{"title":"Replacing Inline Loader Syntax","id":"replacing-inline-loader-syntax","level":2},{"title":"Disable emitting assets","id":"disable-emitting-assets","level":2}],"title":"Asset Modules","sort":25,"contributors":["smelukov","EugeneHlushko","chenxsan","anshumanv","spence-s","dkdk225"],"related":[{"title":"webpack 5 - Asset Modules","url":"https://dev.to/smelukov/webpack-5-asset-modules-2o3h"}]},{"path":"src/content/guides/entry-advanced.mdx","name":"entry-advanced.mdx","size":2072,"type":"file","extension":".mdx","url":"/guides/entry-advanced/","anchors":[{"title":"Multiple file types per entry","id":"multiple-file-types-per-entry","level":2}],"title":"Advanced entry","sort":25,"contributors":["EugeneHlushko"]},{"path":"src/content/guides/package-exports.mdx","name":"package-exports.mdx","size":24715,"type":"file","extension":".mdx","url":"/guides/package-exports/","anchors":[{"title":"General syntax","id":"general-syntax","level":2},{"title":"Alternatives","id":"alternatives","level":2},{"title":"Conditional syntax","id":"conditional-syntax","level":2},{"title":"Abbreviation","id":"abbreviation","level":2},{"title":"Notes about ordering","id":"notes-about-ordering","level":2},{"title":"Support","id":"support","level":2},{"title":"Conditions","id":"conditions","level":2},{"title":"Reference syntax","id":"reference-syntax","level":3},{"title":"Optimizations","id":"optimizations","level":3},{"title":"Target environment","id":"target-environment","level":3},{"title":"Conditions: Preprocessor and runtimes","id":"conditions-preprocessor-and-runtimes","level":3},{"title":"Conditions: Custom","id":"conditions-custom","level":3},{"title":"Common patterns","id":"common-patterns","level":2},{"title":"Target environment independent packages","id":"target-environment-independent-packages","level":3},{"title":"Providing devtools or production optimizations","id":"providing-devtools-or-production-optimizations","level":3},{"title":"Providing different versions depending on target environment","id":"providing-different-versions-depending-on-target-environment","level":3},{"title":"Combining patterns","id":"combining-patterns","level":3},{"title":"Guidelines","id":"guidelines","level":2}],"title":"Package exports","sort":25,"contributors":["sokra"],"related":[{"title":"Package entry points in Node.js","url":"https://nodejs.org/api/packages.html#packages_package_entry_points"}]}],"size":240480,"type":"directory","url":"/guides/"},{"path":"src/content/loaders","name":"loaders","children":[{"path":"src/content/loaders/_babel-loader.mdx","name":"babel-loader.mdx","size":13793,"type":"file","extension":".mdx","url":"/loaders/babel-loader/","anchors":[{"title":"Install","id":"install","level":2},{"title":"Usage","id":"usage","level":2},{"title":"Options","id":"options","level":3},{"title":"Troubleshooting","id":"troubleshooting","level":2},{"title":"babel-loader is slow!","id":"babel-loader-is-slow","level":3},{"title":"Some files in my node_modules are not transpiled for IE 11","id":"some-files-in-my-node_modules-are-not-transpiled-for-ie-11","level":3},{"title":"Babel is injecting helpers into each file and bloating my code!","id":"babel-is-injecting-helpers-into-each-file-and-bloating-my-code","level":3},{"title":"The Node.js API for babel has been moved to babel-core.","id":"the-nodejs-api-for-babel-has-been-moved-to-babel-core","level":3},{"title":"Exclude libraries that should not be transpiled","id":"exclude-libraries-that-should-not-be-transpiled","level":3},{"title":"Top level function (IIFE) is still arrow (on Webpack 5)","id":"top-level-function-iife-is-still-arrow-on-webpack-5","level":3},{"title":"Customize config based on webpack target","id":"customize-config-based-on-webpack-target","level":2},{"title":"Customized Loader","id":"customized-loader","level":2},{"title":"Example","id":"example","level":3},{"title":"customOptions(options: Object): { custom: Object, loader: Object }","id":"customoptionsoptions-object--custom-object-loader-object-","level":3},{"title":"config(cfg: PartialConfig, options: { source, customOptions }): Object","id":"configcfg-partialconfig-options--source-customoptions--object","level":3},{"title":"result(result: Result): Result","id":"resultresult-result-result","level":3},{"title":"License","id":"license","level":2}],"title":"babel-loader","source":"https://raw.githubusercontent.com/babel/babel-loader/main/README.md","edit":"https://github.com/babel/babel-loader/edit/main/README.md","repo":"https://github.com/babel/babel-loader","thirdParty":true},{"path":"src/content/loaders/_coffee-loader.mdx","name":"coffee-loader.mdx","size":5019,"type":"file","extension":".mdx","url":"/loaders/coffee-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"Examples","id":"examples","level":2},{"title":"CoffeeScript and Babel","id":"coffeescript-and-babel","level":3},{"title":"Literate CoffeeScript","id":"literate-coffeescript","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"coffee-loader","source":"https://raw.githubusercontent.com/webpack-contrib/coffee-loader/master/README.md","edit":"https://github.com/webpack-contrib/coffee-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/coffee-loader","thirdParty":true},{"path":"src/content/loaders/_exports-loader.mdx","name":"exports-loader.mdx","size":13582,"type":"file","extension":".mdx","url":"/loaders/exports-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Inline","id":"inline","level":3},{"title":"Using Configuration","id":"using-configuration","level":3},{"title":"Options","id":"options","level":2},{"title":"type","id":"type","level":3},{"title":"exports","id":"exports","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"exports-loader","source":"https://raw.githubusercontent.com/webpack-contrib/exports-loader/master/README.md","edit":"https://github.com/webpack-contrib/exports-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/exports-loader","thirdParty":true},{"path":"src/content/loaders/_expose-loader.mdx","name":"expose-loader.mdx","size":9862,"type":"file","extension":".mdx","url":"/loaders/expose-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Inline","id":"inline","level":2},{"title":"Using Configuration","id":"using-configuration","level":2},{"title":"Options","id":"options","level":2},{"title":"exposes","id":"exposes","level":3},{"title":"globalObject","id":"globalobject","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"expose-loader","source":"https://raw.githubusercontent.com/webpack-contrib/expose-loader/master/README.md","edit":"https://github.com/webpack-contrib/expose-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/expose-loader","thirdParty":true},{"path":"src/content/loaders/_html-loader.mdx","name":"html-loader.mdx","size":24363,"type":"file","extension":".mdx","url":"/loaders/html-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"sources","id":"sources","level":3},{"title":"preprocessor","id":"preprocessor","level":3},{"title":"minimize","id":"minimize","level":3},{"title":"esModule","id":"esmodule","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Disable url resolving using the `` comment","id":"disable-url-resolving-using-the--comment","level":3},{"title":"roots","id":"roots","level":3},{"title":"CDN","id":"cdn","level":3},{"title":"Process script and link tags","id":"process-script-and-link-tags","level":3},{"title":"Templating","id":"templating","level":3},{"title":"PostHTML","id":"posthtml","level":3},{"title":"Export into HTML files","id":"export-into-html-files","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"html-loader","source":"https://raw.githubusercontent.com/webpack-contrib/html-loader/master/README.md","edit":"https://github.com/webpack-contrib/html-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/html-loader","thirdParty":true},{"path":"src/content/loaders/_imports-loader.mdx","name":"imports-loader.mdx","size":17274,"type":"file","extension":".mdx","url":"/loaders/imports-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Inline","id":"inline","level":3},{"title":"Using Configuration","id":"using-configuration","level":3},{"title":"Options","id":"options","level":2},{"title":"type","id":"type","level":3},{"title":"imports","id":"imports","level":3},{"title":"wrapper","id":"wrapper","level":3},{"title":"additionalCode","id":"additionalcode","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"imports-loader","source":"https://raw.githubusercontent.com/webpack-contrib/imports-loader/master/README.md","edit":"https://github.com/webpack-contrib/imports-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/imports-loader","thirdParty":true},{"path":"src/content/loaders/index.mdx","name":"index.mdx","size":4115,"type":"file","extension":".mdx","url":"/loaders/","anchors":[{"title":"Files","id":"files","level":2},{"title":"JSON","id":"json","level":2},{"title":"Transpiling","id":"transpiling","level":2},{"title":"Templating","id":"templating","level":2},{"title":"Styling","id":"styling","level":2},{"title":"Frameworks","id":"frameworks","level":2},{"title":"Awesome","id":"awesome","level":2}],"title":"Loaders","sort":-1,"contributors":["simon04","bajras","rhys-vdw","EugeneHlushko","hemal7735","snitin315","anshumanv","jamesgeorge007","chenxsan"]},{"path":"src/content/loaders/_node-loader.mdx","name":"node-loader.mdx","size":5276,"type":"file","extension":".mdx","url":"/loaders/node-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Inline","id":"inline","level":3},{"title":"Configuration","id":"configuration","level":3},{"title":"Options","id":"options","level":2},{"title":"flags","id":"flags","level":3},{"title":"name","id":"name","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"node-loader","source":"https://raw.githubusercontent.com/webpack-contrib/node-loader/master/README.md","edit":"https://github.com/webpack-contrib/node-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/node-loader","thirdParty":true},{"path":"src/content/loaders/_remark-loader.mdx","name":"remark-loader.mdx","size":8153,"type":"file","extension":".mdx","url":"/loaders/remark-loader/","anchors":[{"title":"Usage","id":"usage","level":2},{"title":"Options","id":"options","level":2},{"title":"remarkOptions","id":"remarkoptions","level":3},{"title":"removeFrontMatter","id":"removefrontmatter","level":3},{"title":"Inspiration","id":"inspiration","level":2},{"title":"Examples","id":"examples","level":2},{"title":"Markdown to HTML","id":"markdown-to-html","level":3},{"title":"Markdown to Markdown","id":"markdown-to-markdown","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"remark-loader","source":"https://raw.githubusercontent.com/webpack-contrib/remark-loader/master/README.md","edit":"https://github.com/webpack-contrib/remark-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/remark-loader","thirdParty":true},{"path":"src/content/loaders/_source-map-loader.mdx","name":"source-map-loader.mdx","size":5406,"type":"file","extension":".mdx","url":"/loaders/source-map-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"filterSourceMappingUrl","id":"filtersourcemappingurl","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Ignoring Warnings","id":"ignoring-warnings","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"source-map-loader","source":"https://raw.githubusercontent.com/webpack-contrib/source-map-loader/master/README.md","edit":"https://github.com/webpack-contrib/source-map-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/source-map-loader","thirdParty":true},{"path":"src/content/loaders/_thread-loader.mdx","name":"thread-loader.mdx","size":4455,"type":"file","extension":".mdx","url":"/loaders/thread-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Examples","id":"examples","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"thread-loader","source":"https://raw.githubusercontent.com/webpack-contrib/thread-loader/master/README.md","edit":"https://github.com/webpack-contrib/thread-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/thread-loader","thirdParty":true},{"path":"src/content/loaders/_val-loader.mdx","name":"val-loader.mdx","size":10033,"type":"file","extension":".mdx","url":"/loaders/val-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"executableFile","id":"executablefile","level":3},{"title":"Return Object Properties","id":"return-object-properties","level":2},{"title":"code","id":"code","level":3},{"title":"sourceMap","id":"sourcemap","level":3},{"title":"ast","id":"ast","level":3},{"title":"dependencies","id":"dependencies","level":3},{"title":"contextDependencies","id":"contextdependencies","level":3},{"title":"buildDependencies","id":"builddependencies","level":3},{"title":"cacheable","id":"cacheable","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Simple","id":"simple","level":3},{"title":"Modernizr","id":"modernizr","level":3},{"title":"Figlet","id":"figlet","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"val-loader","source":"https://raw.githubusercontent.com/webpack-contrib/val-loader/master/README.md","edit":"https://github.com/webpack-contrib/val-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/val-loader","thirdParty":true},{"path":"src/content/loaders/_css-loader.mdx","name":"css-loader.mdx","size":45788,"type":"file","extension":".mdx","url":"/loaders/css-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"url","id":"url","level":3},{"title":"import","id":"import","level":3},{"title":"modules","id":"modules","level":3},{"title":"importLoaders","id":"importloaders","level":3},{"title":"sourceMap","id":"sourcemap","level":3},{"title":"esModule","id":"esmodule","level":3},{"title":"exportType","id":"exporttype","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Recommend","id":"recommend","level":3},{"title":"Disable url resolving using the /* webpackIgnore: true */ comment","id":"disable-url-resolving-using-the--webpackignore-true--comment","level":3},{"title":"Assets","id":"assets","level":3},{"title":"Extract","id":"extract","level":3},{"title":"Pure CSS, CSS modules and PostCSS","id":"pure-css-css-modules-and-postcss","level":3},{"title":"Resolve unresolved URLs using an alias","id":"resolve-unresolved-urls-using-an-alias","level":3},{"title":"Named export with custom export names","id":"named-export-with-custom-export-names","level":3},{"title":"Separating Interoperable CSS-only and CSS Module features","id":"separating-interoperable-css-only-and-css-module-features","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"css-loader","source":"https://raw.githubusercontent.com/webpack-contrib/css-loader/master/README.md","edit":"https://github.com/webpack-contrib/css-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/css-loader","thirdParty":true,"group":"CSS"},{"path":"src/content/loaders/_less-loader.mdx","name":"less-loader.mdx","size":15774,"type":"file","extension":".mdx","url":"/loaders/less-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"lessOptions","id":"lessoptions","level":3},{"title":"additionalData","id":"additionaldata","level":3},{"title":"sourceMap","id":"sourcemap","level":3},{"title":"webpackImporter","id":"webpackimporter","level":3},{"title":"implementation","id":"implementation","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Normal usage","id":"normal-usage","level":3},{"title":"Source maps","id":"source-maps","level":3},{"title":"In production","id":"in-production","level":3},{"title":"Imports","id":"imports","level":3},{"title":"Plugins","id":"plugins","level":3},{"title":"Extracting style sheets","id":"extracting-style-sheets","level":3},{"title":"CSS modules gotcha","id":"css-modules-gotcha","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"less-loader","source":"https://raw.githubusercontent.com/webpack-contrib/less-loader/master/README.md","edit":"https://github.com/webpack-contrib/less-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/less-loader","thirdParty":true,"group":"CSS"},{"path":"src/content/loaders/_postcss-loader.mdx","name":"postcss-loader.mdx","size":25177,"type":"file","extension":".mdx","url":"/loaders/postcss-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"execute","id":"execute","level":3},{"title":"postcssOptions","id":"postcssoptions","level":3},{"title":"sourceMap","id":"sourcemap","level":3},{"title":"implementation","id":"implementation","level":3},{"title":"Examples","id":"examples","level":2},{"title":"SugarSS","id":"sugarss","level":3},{"title":"Autoprefixer","id":"autoprefixer","level":3},{"title":"PostCSS Preset Env","id":"postcss-preset-env","level":3},{"title":"CSS Modules","id":"css-modules","level":3},{"title":"Extract CSS","id":"extract-css","level":3},{"title":"Emit assets","id":"emit-assets","level":3},{"title":"Add dependencies, contextDependencies, buildDependencies, missingDependencies","id":"add-dependencies-contextdependencies-builddependencies-missingdependencies","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"postcss-loader","source":"https://raw.githubusercontent.com/webpack-contrib/postcss-loader/master/README.md","edit":"https://github.com/webpack-contrib/postcss-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/postcss-loader","thirdParty":true,"group":"CSS"},{"path":"src/content/loaders/_sass-loader.mdx","name":"sass-loader.mdx","size":24121,"type":"file","extension":".mdx","url":"/loaders/sass-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"The outputStyle (old API) and style (new API) options in production mode","id":"the-outputstyle-old-api-and-style-new-api-options-in-production-mode","level":3},{"title":"Resolving import at-rules","id":"resolving-import-at-rules","level":3},{"title":"Problems with url(...)","id":"problems-with-url","level":3},{"title":"Options","id":"options","level":2},{"title":"implementation","id":"implementation","level":3},{"title":"sassOptions","id":"sassoptions","level":3},{"title":"sourceMap","id":"sourcemap","level":3},{"title":"additionalData","id":"additionaldata","level":3},{"title":"webpackImporter","id":"webpackimporter","level":3},{"title":"warnRuleAsWarning","id":"warnruleaswarning","level":3},{"title":"api","id":"api","level":3},{"title":"How to enable @debug output","id":"how-to-enable-debug-output","level":2},{"title":"Examples","id":"examples","level":2},{"title":"Extracts CSS into separate files","id":"extracts-css-into-separate-files","level":3},{"title":"Source maps","id":"source-maps","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"sass-loader","source":"https://raw.githubusercontent.com/webpack-contrib/sass-loader/master/README.md","edit":"https://github.com/webpack-contrib/sass-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/sass-loader","thirdParty":true,"group":"CSS"},{"path":"src/content/loaders/_style-loader.mdx","name":"style-loader.mdx","size":27281,"type":"file","extension":".mdx","url":"/loaders/style-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"injectType","id":"injecttype","level":3},{"title":"attributes","id":"attributes","level":3},{"title":"insert","id":"insert","level":3},{"title":"styleTagTransform","id":"styletagtransform","level":3},{"title":"base","id":"base","level":3},{"title":"esModule","id":"esmodule","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Recommend","id":"recommend","level":3},{"title":"Named export for CSS Modules","id":"named-export-for-css-modules","level":3},{"title":"Source maps","id":"source-maps","level":3},{"title":"Nonce","id":"nonce","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"style-loader","source":"https://raw.githubusercontent.com/webpack-contrib/style-loader/master/README.md","edit":"https://github.com/webpack-contrib/style-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/style-loader","thirdParty":true,"group":"CSS"},{"path":"src/content/loaders/_stylus-loader.mdx","name":"stylus-loader.mdx","size":18226,"type":"file","extension":".mdx","url":"/loaders/stylus-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"stylusOptions","id":"stylusoptions","level":3},{"title":"sourceMap","id":"sourcemap","level":3},{"title":"webpackImporter","id":"webpackimporter","level":3},{"title":"additionalData","id":"additionaldata","level":3},{"title":"implementation","id":"implementation","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Normal usage","id":"normal-usage","level":3},{"title":"Source maps","id":"source-maps","level":3},{"title":"Using nib with stylus","id":"using-nib-with-stylus","level":3},{"title":"Import JSON files","id":"import-json-files","level":3},{"title":"In production","id":"in-production","level":3},{"title":"webpack resolver","id":"webpack-resolver","level":3},{"title":"Stylus resolver","id":"stylus-resolver","level":3},{"title":"Extracting style sheets","id":"extracting-style-sheets","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"stylus-loader","source":"https://raw.githubusercontent.com/webpack-contrib/stylus-loader/master/README.md","edit":"https://github.com/webpack-contrib/stylus-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/stylus-loader","thirdParty":true,"group":"CSS"}],"size":277698,"type":"directory","url":"/loaders/"},{"path":"src/content/migrate","name":"migrate","children":[{"path":"src/content/migrate/index.mdx","name":"index.mdx","size":161,"type":"file","extension":".mdx","url":"/migrate/","anchors":[],"title":"Migrate","sort":-1,"contributors":["EugeneHlushko"]},{"path":"src/content/migrate/5.mdx","name":"5.mdx","size":15701,"type":"file","extension":".mdx","url":"/migrate/5/","anchors":[{"title":"Preparations","id":"preparations","level":2},{"title":"Upgrade webpack 4 and its plugins/loaders","id":"upgrade-webpack-4-and-its-pluginsloaders","level":2},{"title":"Make sure your build has no errors or warnings","id":"make-sure-your-build-has-no-errors-or-warnings","level":3},{"title":"Make sure to use mode","id":"make-sure-to-use-mode","level":3},{"title":"Update outdated options","id":"update-outdated-options","level":3},{"title":"Test webpack 5 compatibility","id":"test-webpack-5-compatibility","level":3},{"title":"Upgrade webpack to 5","id":"upgrade-webpack-to-5","level":2},{"title":"Clean up configuration","id":"clean-up-configuration","level":3},{"title":"Need to support an older browser like IE 11?","id":"need-to-support-an-older-browser-like-ie-11","level":3},{"title":"Cleanup the code","id":"cleanup-the-code","level":3},{"title":"Run a single build and follow advice","id":"run-a-single-build-and-follow-advice","level":3},{"title":"Everything works?","id":"everything-works","level":2},{"title":"It is not working?","id":"it-is-not-working","level":2},{"title":"Something missing in this guide?","id":"something-missing-in-this-guide","level":2},{"title":"Changes to internals","id":"changes-to-internals","level":2},{"title":"getOptions method for Loaders","id":"getoptions-method-for-loaders","level":3}],"title":"To v5 from v4","sort":1,"contributors":["sokra","salemhilal","keichinger","EugeneHlushko","MattGoldwater","rramaa","chenxsan","jamesgeorge007","getsnoopy","yevhen-logosha"]},{"path":"src/content/migrate/4.mdx","name":"4.mdx","size":4115,"type":"file","extension":".mdx","url":"/migrate/4/","anchors":[{"title":"Node.js v4","id":"nodejs-v4","level":2},{"title":"CLI","id":"cli","level":2},{"title":"Update plugins","id":"update-plugins","level":2},{"title":"mode","id":"mode","level":2},{"title":"Deprecated/Removed plugins","id":"deprecatedremoved-plugins","level":2},{"title":"CommonsChunkPlugin","id":"commonschunkplugin","level":2},{"title":"import() and CommonJS","id":"import-and-commonjs","level":2},{"title":"json and loaders","id":"json-and-loaders","level":2},{"title":"module.loaders","id":"moduleloaders","level":2}],"title":"To v4 from v3","sort":2,"contributors":["sokra","EugeneHlushko","Kolhar730"],"related":[{"title":"To v2 or v3 from v1","url":"https://webpack.js.org/migrate/3/"},{"title":"RIP CommonChunkPlugin","url":"https://gist.github.com/sokra/1522d586b8e5c0f5072d7565c2bee693"},{"title":"webpack 4: migration guide for plugins/loaders","url":"https://medium.com/webpack/webpack-4-migration-guide-for-plugins-loaders-20a79b927202"}]},{"path":"src/content/migrate/3.mdx","name":"3.mdx","size":16052,"type":"file","extension":".mdx","url":"/migrate/3/","anchors":[{"title":"resolve.root, resolve.fallback, resolve.modulesDirectories","id":"resolveroot-resolvefallback-resolvemodulesdirectories","level":2},{"title":"resolve.extensions","id":"resolveextensions","level":2},{"title":"resolve.*","id":"resolve","level":2},{"title":"module.loaders is now module.rules","id":"moduleloaders-is-now-modulerules","level":2},{"title":"Chaining loaders","id":"chaining-loaders","level":2},{"title":"Automatic -loader module name extension removed","id":"automatic--loader-module-name-extension-removed","level":2},{"title":"json-loader is not required anymore","id":"json-loader-is-not-required-anymore","level":2},{"title":"Loaders in configuration resolve relative to context","id":"loaders-in-configuration-resolve-relative-to-context","level":2},{"title":"module.preLoaders and module.postLoaders were removed:","id":"modulepreloaders-and-modulepostloaders-were-removed","level":2},{"title":"UglifyJsPlugin sourceMap","id":"uglifyjsplugin-sourcemap","level":2},{"title":"UglifyJsPlugin warnings","id":"uglifyjsplugin-warnings","level":2},{"title":"UglifyJsPlugin minimize loaders","id":"uglifyjsplugin-minimize-loaders","level":2},{"title":"DedupePlugin has been removed","id":"dedupeplugin-has-been-removed","level":2},{"title":"BannerPlugin - breaking change","id":"bannerplugin---breaking-change","level":2},{"title":"OccurrenceOrderPlugin is now on by default","id":"occurrenceorderplugin-is-now-on-by-default","level":2},{"title":"ExtractTextWebpackPlugin - breaking change","id":"extracttextwebpackplugin---breaking-change","level":2},{"title":"ExtractTextPlugin.extract","id":"extracttextpluginextract","level":3},{"title":"new ExtractTextPlugin({options})","id":"new-extracttextpluginoptions","level":3},{"title":"Full dynamic requires now fail by default","id":"full-dynamic-requires-now-fail-by-default","level":2},{"title":"Using custom arguments in CLI and configuration","id":"using-custom-arguments-in-cli-and-configuration","level":3},{"title":"require.ensure and AMD require are asynchronous","id":"requireensure-and-amd-require-are-asynchronous","level":2},{"title":"Loader configuration is through options","id":"loader-configuration-is-through-options","level":2},{"title":"What are options?","id":"what-are-options","level":3},{"title":"LoaderOptionsPlugin context","id":"loaderoptionsplugin-context","level":2},{"title":"debug","id":"debug","level":2},{"title":"Code Splitting with ES2015","id":"code-splitting-with-es2015","level":2},{"title":"Dynamic expressions","id":"dynamic-expressions","level":2},{"title":"Mixing ES2015 with AMD and CommonJS","id":"mixing-es2015-with-amd-and-commonjs","level":2},{"title":"Hints","id":"hints","level":2},{"title":"Template strings","id":"template-strings","level":3},{"title":"Configuration Promise","id":"configuration-promise","level":3},{"title":"Advanced loader matching","id":"advanced-loader-matching","level":3},{"title":"More CLI options","id":"more-cli-options","level":3},{"title":"Loader changes","id":"loader-changes","level":2},{"title":"Cacheable","id":"cacheable","level":3},{"title":"Complex options","id":"complex-options","level":3}],"title":"To v2 or v3 from v1","sort":3,"contributors":["sokra","jhnns","grgur","domfarolino","johnnyreilly","jouni-kantola","frederikprijck","chrisVillanueva","bebraw","howdy39","selbekk","ndelangen","EugeneHlushko","byzyk"]}],"size":36029,"type":"directory","url":"/migrate/"},{"path":"src/content/plugins","name":"plugins","children":[{"path":"src/content/plugins/index.mdx","name":"index.mdx","size":4929,"type":"file","extension":".mdx","url":"/plugins/","anchors":[],"title":"Plugins","sort":-1,"contributors":["simon04","gonzoyumo","rouzbeh84","aretecode","eko3alpha","refactorized","byzyk","EugeneHlushko","snitin315","chenxsan"]},{"path":"src/content/plugins/html-webpack-plugin.mdx","name":"html-webpack-plugin.mdx","size":2010,"type":"file","extension":".mdx","url":"/plugins/html-webpack-plugin/","anchors":[{"title":"Installation","id":"installation","level":2},{"title":"Basic Usage","id":"basic-usage","level":2},{"title":"Configuration","id":"configuration","level":2},{"title":"Third party addons","id":"third-party-addons","level":2}],"title":"HtmlWebpackPlugin","group":"Community","contributors":["ampedandwired","simon04","Sibiraj-S","EugeneHlushko"]},{"path":"src/content/plugins/_svg-chunk-webpack-plugin.mdx","name":"svg-chunk-webpack-plugin.mdx","size":8954,"type":"file","extension":".mdx","url":"/plugins/svg-chunk-webpack-plugin/","anchors":[{"title":"When to use this plugin","id":"when-to-use-this-plugin","level":2},{"title":"Zero config","id":"zero-config","level":2},{"title":"Installation","id":"installation","level":2},{"title":"Example","id":"example","level":2},{"title":"Basic usage","id":"basic-usage","level":2},{"title":"Using a configuration","id":"using-a-configuration","level":2},{"title":"Loader","id":"loader","level":3},{"title":"Plugin","id":"plugin","level":3},{"title":"filename","id":"filename","level":3},{"title":"svgstoreConfig","id":"svgstoreconfig","level":3},{"title":"generateSpritesManifest","id":"generatespritesmanifest","level":3},{"title":"generateSpritesPreview","id":"generatespritespreview","level":3},{"title":"Caching","id":"caching","level":2},{"title":"[contenthash]","id":"contenthash","level":3},{"title":"[fullhash]","id":"fullhash","level":3},{"title":"License","id":"license","level":2}],"title":"SvgChunkWebpackPlugin","group":"Community","contributors":["yoriiis","alexander-akait"],"source":"https://raw.githubusercontent.com/yoriiis/svg-chunk-webpack-plugin/main/README.md","edit":"https://github.com/yoriiis/svg-chunk-webpack-plugin/edit/main/README.md","repo":"https://github.com/yoriiis/svg-chunk-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/automatic-prefetch-plugin.mdx","name":"automatic-prefetch-plugin.mdx","size":591,"type":"file","extension":".mdx","url":"/plugins/automatic-prefetch-plugin/","anchors":[],"title":"AutomaticPrefetchPlugin","group":"webpack","contributors":["sokra","EugeneHlushko"]},{"path":"src/content/plugins/banner-plugin.mdx","name":"banner-plugin.mdx","size":1652,"type":"file","extension":".mdx","url":"/plugins/banner-plugin/","anchors":[{"title":"Options","id":"options","level":2},{"title":"Usage","id":"usage","level":2},{"title":"Placeholders","id":"placeholders","level":2}],"title":"BannerPlugin","group":"webpack","contributors":["simon04","byzyk","chenxsan"],"related":[{"title":"banner-plugin-hashing test","url":"https://github.com/webpack/webpack/blob/master/test/configCases/plugins/banner-plugin-hashing/webpack.config.js"}]},{"path":"src/content/plugins/commons-chunk-plugin.mdx","name":"commons-chunk-plugin.mdx","size":9405,"type":"file","extension":".mdx","url":"/plugins/commons-chunk-plugin/","anchors":[{"title":"Options","id":"options","level":2},{"title":"Examples","id":"examples","level":2},{"title":"Commons chunk for entries","id":"commons-chunk-for-entries","level":3},{"title":"Explicit vendor chunk","id":"explicit-vendor-chunk","level":3},{"title":"Move common modules into the parent chunk","id":"move-common-modules-into-the-parent-chunk","level":3},{"title":"Extra async commons chunk","id":"extra-async-commons-chunk","level":3},{"title":"Passing the minChunks property a function","id":"passing-the-minchunks-property-a-function","level":3},{"title":"Manifest file","id":"manifest-file","level":2},{"title":"Combining implicit common vendor chunks and manifest file","id":"combining-implicit-common-vendor-chunks-and-manifest-file","level":2},{"title":"More Examples","id":"more-examples","level":2}],"title":"CommonsChunkPlugin","group":"webpack","contributors":["bebraw","simon04","christopher4lis","kevinzwhuang","jdbevan","jeremenichelli","byzyk","madhavarshney","snitin315"]},{"path":"src/content/plugins/context-exclusion-plugin.mdx","name":"context-exclusion-plugin.mdx","size":516,"type":"file","extension":".mdx","url":"/plugins/context-exclusion-plugin/","anchors":[],"title":"ContextExclusionPlugin","group":"webpack","contributors":["jeffin"]},{"path":"src/content/plugins/context-replacement-plugin.mdx","name":"context-replacement-plugin.mdx","size":3107,"type":"file","extension":".mdx","url":"/plugins/context-replacement-plugin/","anchors":[{"title":"Usage","id":"usage","level":2},{"title":"Content Callback","id":"content-callback","level":2},{"title":"Other Options","id":"other-options","level":2}],"title":"ContextReplacementPlugin","group":"webpack","contributors":["simon04","byzyk","masives","chenxsan"],"related":[{"title":"Issue 2783 - ContextReplacementPlugin Description","url":"https://github.com/webpack/webpack/issues/2783#issuecomment-234137265"},{"title":"Using context replacement module for date-fns","url":"https://github.com/date-fns/date-fns/blob/master/docs/webpack.md"}]},{"path":"src/content/plugins/define-plugin.mdx","name":"define-plugin.mdx","size":4474,"type":"file","extension":".mdx","url":"/plugins/define-plugin/","anchors":[{"title":"Usage","id":"usage","level":2},{"title":"Feature Flags","id":"feature-flags","level":2},{"title":"Service URLs","id":"service-urls","level":2},{"title":"Runtime values via runtimeValue","id":"runtime-values-via-runtimevalue","level":2}],"title":"DefinePlugin","group":"webpack","contributors":["simon04","rouzbeh84","byzyk","EugeneHlushko","smonusbonus","chenxsan"]},{"path":"src/content/plugins/dll-plugin.mdx","name":"dll-plugin.mdx","size":5604,"type":"file","extension":".mdx","url":"/plugins/dll-plugin/","anchors":[{"title":"DllPlugin","id":"dllplugin","level":2},{"title":"DllReferencePlugin","id":"dllreferenceplugin","level":2},{"title":"Modes","id":"modes","level":3},{"title":"Usage","id":"usage","level":2},{"title":"Examples","id":"examples","level":2},{"title":"References","id":"references","level":2},{"title":"Source","id":"source","level":3},{"title":"Tests","id":"tests","level":3}],"title":"DllPlugin","group":"webpack","contributors":["aretecode","sokra","opiepj","simon04","skipjack","byzyk","EugeneHlushko","EslamHiko","snitin315"],"related":[{"title":"Code Splitting Example","url":"https://github.com/webpack/webpack/blob/master/examples/explicit-vendor-chunk/README.md"}]},{"path":"src/content/plugins/environment-plugin.mdx","name":"environment-plugin.mdx","size":3629,"type":"file","extension":".mdx","url":"/plugins/environment-plugin/","anchors":[{"title":"Usage","id":"usage","level":2},{"title":"Usage with default values","id":"usage-with-default-values","level":2},{"title":"Use Case: Git Version","id":"use-case-git-version","level":2},{"title":"DotenvPlugin","id":"dotenvplugin","level":2}],"title":"EnvironmentPlugin","group":"webpack","contributors":["simon04","einarlove","rouzbeh84","byzyk"]},{"path":"src/content/plugins/eval-source-map-dev-tool-plugin.mdx","name":"eval-source-map-dev-tool-plugin.mdx","size":2779,"type":"file","extension":".mdx","url":"/plugins/eval-source-map-dev-tool-plugin/","anchors":[{"title":"Options","id":"options","level":2},{"title":"Examples","id":"examples","level":2},{"title":"Basic Use Case","id":"basic-use-case","level":3},{"title":"Exclude Vendor Maps","id":"exclude-vendor-maps","level":3}],"title":"EvalSourceMapDevToolPlugin","group":"webpack","contributors":["johnnyreilly","simon04","kinseyost","byzyk","madhavarshney","koke","jamesgeorge007","anshumanv","EugeneHlushko"],"related":[{"title":"Building Eval Source Maps","url":"https://survivejs.com/webpack/building/source-maps/#sourcemapdevtoolplugin-and-evalsourcemapdevtoolplugin"}]},{"path":"src/content/plugins/hashed-module-ids-plugin.mdx","name":"hashed-module-ids-plugin.mdx","size":1288,"type":"file","extension":".mdx","url":"/plugins/hashed-module-ids-plugin/","anchors":[{"title":"Options","id":"options","level":2},{"title":"Usage","id":"usage","level":2}],"title":"HashedModuleIdsPlugin","group":"webpack","contributors":["shaodahong","byzyk","EslamHiko"]},{"path":"src/content/plugins/hot-module-replacement-plugin.mdx","name":"hot-module-replacement-plugin.mdx","size":608,"type":"file","extension":".mdx","url":"/plugins/hot-module-replacement-plugin/","anchors":[{"title":"Basic Usage","id":"basic-usage","level":2}],"title":"HotModuleReplacementPlugin","group":"webpack","contributors":["skipjack","byzyk","chenxsan","snitin315"],"related":[{"title":"Concepts - Hot Module Replacement","url":"/concepts/hot-module-replacement"},{"title":"API - Hot Module Replacement","url":"/api/hot-module-replacement"}]},{"path":"src/content/plugins/ignore-plugin.mdx","name":"ignore-plugin.mdx","size":2077,"type":"file","extension":".mdx","url":"/plugins/ignore-plugin/","anchors":[{"title":"Using regular expressions","id":"using-regular-expressions","level":2},{"title":"Using filter functions","id":"using-filter-functions","level":2},{"title":"Example of ignoring Moment Locales","id":"example-of-ignoring-moment-locales","level":2}],"title":"IgnorePlugin","group":"webpack","contributors":["simon04","byzyk","DullReferenceException","EugeneHlushko","FadySamirSadek","iamakulov","chenxsan"]},{"path":"src/content/plugins/internal-plugins.mdx","name":"internal-plugins.mdx","size":9140,"type":"file","extension":".mdx","url":"/plugins/internal-plugins/","anchors":[{"title":"environment","id":"environment","level":2},{"title":"NodeEnvironmentPlugin","id":"nodeenvironmentplugin","level":3},{"title":"compiler","id":"compiler","level":2},{"title":"MemoryCachePlugin","id":"memorycacheplugin","level":3},{"title":"ProgressPlugin","id":"progressplugin","level":3},{"title":"RecordIdsPlugin","id":"recordidsplugin","level":3},{"title":"entry","id":"entry","level":2},{"title":"EntryPlugin","id":"entryplugin","level":3},{"title":"PrefetchPlugin","id":"prefetchplugin","level":3},{"title":"output","id":"output","level":2},{"title":"JsonpTemplatePlugin","id":"jsonptemplateplugin","level":3},{"title":"NodeTemplatePlugin","id":"nodetemplateplugin","level":3},{"title":"LibraryTemplatePlugin","id":"librarytemplateplugin","level":3},{"title":"WebWorkerTemplatePlugin","id":"webworkertemplateplugin","level":3},{"title":"EvalDevToolModulePlugin","id":"evaldevtoolmoduleplugin","level":3},{"title":"SourceMapDevToolPlugin","id":"sourcemapdevtoolplugin","level":3},{"title":"HotModuleReplacementPlugin","id":"hotmodulereplacementplugin","level":3},{"title":"source","id":"source","level":2},{"title":"APIPlugin","id":"apiplugin","level":3},{"title":"CompatibilityPlugin","id":"compatibilityplugin","level":3},{"title":"ConstPlugin","id":"constplugin","level":3},{"title":"ProvidePlugin","id":"provideplugin","level":3},{"title":"NodeStuffPlugin","id":"nodestuffplugin","level":3},{"title":"RequireJsStuffPlugin","id":"requirejsstuffplugin","level":3},{"title":"NodeSourcePlugin","id":"nodesourceplugin","level":3},{"title":"NodeTargetPlugin","id":"nodetargetplugin","level":3},{"title":"AMDPlugin","id":"amdplugin","level":3},{"title":"CommonJsPlugin","id":"commonjsplugin","level":3},{"title":"RequireContextPlugin","id":"requirecontextplugin","level":3},{"title":"RequireEnsurePlugin","id":"requireensureplugin","level":3},{"title":"RequireIncludePlugin","id":"requireincludeplugin","level":3},{"title":"DefinePlugin","id":"defineplugin","level":3},{"title":"optimize","id":"optimize","level":2},{"title":"LimitChunkCountPlugin","id":"limitchunkcountplugin","level":3},{"title":"MergeDuplicateChunksPlugin","id":"mergeduplicatechunksplugin","level":3},{"title":"RemoveEmptyChunksPlugin","id":"removeemptychunksplugin","level":3},{"title":"MinChunkSizePlugin","id":"minchunksizeplugin","level":3},{"title":"ModuleConcatenationPlugin","id":"moduleconcatenationplugin","level":3},{"title":"FlagIncludedChunksPlugin","id":"flagincludedchunksplugin","level":3},{"title":"RealContentHashPlugin","id":"realcontenthashplugin","level":3}],"title":"Internal webpack plugins","group":"webpack","contributors":["iAziz786","EugeneHlushko","ooflorent","Legends","chenxsan"]},{"path":"src/content/plugins/limit-chunk-count-plugin.mdx","name":"limit-chunk-count-plugin.mdx","size":1278,"type":"file","extension":".mdx","url":"/plugins/limit-chunk-count-plugin/","anchors":[{"title":"Options","id":"options","level":2},{"title":"maxChunks","id":"maxchunks","level":3},{"title":"minChunkSize","id":"minchunksize","level":3},{"title":"Usage via CLI","id":"usage-via-cli","level":2}],"title":"LimitChunkCountPlugin","group":"webpack","contributors":["rouzbeh84","skipjack","tbroadley","byzyk","EugeneHlushko","erykpiast"]},{"path":"src/content/plugins/min-chunk-size-plugin.mdx","name":"min-chunk-size-plugin.mdx","size":449,"type":"file","extension":".mdx","url":"/plugins/min-chunk-size-plugin/","anchors":[{"title":"Usage via CLI","id":"usage-via-cli","level":2}],"title":"MinChunkSizePlugin","group":"webpack","contributors":["byzyk","erykpiast"]},{"path":"src/content/plugins/module-concatenation-plugin.mdx","name":"module-concatenation-plugin.mdx","size":4259,"type":"file","extension":".mdx","url":"/plugins/module-concatenation-plugin/","anchors":[{"title":"Optimization Bailouts","id":"optimization-bailouts","level":2},{"title":"Module Grouping Algorithm","id":"module-grouping-algorithm","level":3},{"title":"Debugging Optimization Bailouts","id":"debugging-optimization-bailouts","level":3}],"title":"ModuleConcatenationPlugin","group":"webpack","contributors":["skipjack","TheLarkInn","byzyk"]},{"path":"src/content/plugins/module-federation-plugin.mdx","name":"module-federation-plugin.mdx","size":8517,"type":"file","extension":".mdx","url":"/plugins/module-federation-plugin/","anchors":[{"title":"Options","id":"options","level":2},{"title":"runtime","id":"runtime","level":3},{"title":"Sharing libraries","id":"sharing-libraries","level":3}],"title":"ModuleFederationPlugin","group":"webpack","contributors":["XiaofengXie16","chenxsan","burhanuday","christian24"],"related":[{"title":"Module Federation","url":"/concepts/module-federation/"}]},{"path":"src/content/plugins/NoEmitOnErrorsPlugin.mdx","name":"NoEmitOnErrorsPlugin.mdx","size":434,"type":"file","extension":".mdx","url":"/plugins/NoEmitOnErrorsPlugin/","anchors":[],"title":"NoEmitOnErrorsPlugin","group":"webpack","contributors":["jeffin","chenxsan","snitin315"]},{"path":"src/content/plugins/normal-module-replacement-plugin.mdx","name":"normal-module-replacement-plugin.mdx","size":2476,"type":"file","extension":".mdx","url":"/plugins/normal-module-replacement-plugin/","anchors":[{"title":"Basic Example","id":"basic-example","level":2},{"title":"Advanced Example","id":"advanced-example","level":2}],"title":"NormalModuleReplacementPlugin","group":"webpack","contributors":["gonzoyumo","byzyk","chenxsan"]},{"path":"src/content/plugins/prefetch-plugin.mdx","name":"prefetch-plugin.mdx","size":503,"type":"file","extension":".mdx","url":"/plugins/prefetch-plugin/","anchors":[{"title":"Options","id":"options","level":2}],"title":"PrefetchPlugin","group":"webpack","contributors":["skipjack","byzyk"]},{"path":"src/content/plugins/profiling-plugin.mdx","name":"profiling-plugin.mdx","size":937,"type":"file","extension":".mdx","url":"/plugins/profiling-plugin/","anchors":[{"title":"Options","id":"options","level":2},{"title":"Usage: default","id":"usage-default","level":2},{"title":"Usage: custom outputPath","id":"usage-custom-outputpath","level":2}],"title":"ProfilingPlugin","group":"webpack","contributors":["EugeneHlushko","byzyk","akgupta0777"]},{"path":"src/content/plugins/progress-plugin.mdx","name":"progress-plugin.mdx","size":4986,"type":"file","extension":".mdx","url":"/plugins/progress-plugin/","anchors":[{"title":"Usage","id":"usage","level":2},{"title":"Providing function","id":"providing-function","level":3},{"title":"Providing object","id":"providing-object","level":3},{"title":"webpack.ProgressPlugin.createDefaultHandler","id":"webpackprogressplugincreatedefaulthandler","level":3},{"title":"Percentage calculation","id":"percentage-calculation","level":2},{"title":"Supported Hooks","id":"supported-hooks","level":2},{"title":"Source","id":"source","level":2}],"title":"ProgressPlugin","group":"webpack","contributors":["elliottsj","EugeneHlushko","byzyk","smelukov","chenxsan"]},{"path":"src/content/plugins/provide-plugin.mdx","name":"provide-plugin.mdx","size":1893,"type":"file","extension":".mdx","url":"/plugins/provide-plugin/","anchors":[{"title":"Usage: jQuery","id":"usage-jquery","level":2},{"title":"Usage: jQuery with Angular 1","id":"usage-jquery-with-angular-1","level":2},{"title":"Usage: Lodash Map","id":"usage-lodash-map","level":2},{"title":"Usage: Vue.js","id":"usage-vuejs","level":3}],"title":"ProvidePlugin","group":"webpack","contributors":["sokra","simon04","re-fort","byzyk","seckin92"]},{"path":"src/content/plugins/source-map-dev-tool-plugin.mdx","name":"source-map-dev-tool-plugin.mdx","size":4597,"type":"file","extension":".mdx","url":"/plugins/source-map-dev-tool-plugin/","anchors":[{"title":"Options","id":"options","level":2},{"title":"Examples","id":"examples","level":2},{"title":"Basic Use Case","id":"basic-use-case","level":3},{"title":"Exclude Vendor Maps","id":"exclude-vendor-maps","level":3},{"title":"Host Source Maps Externally","id":"host-source-maps-externally","level":3}],"title":"SourceMapDevToolPlugin","group":"webpack","contributors":["johnnyreilly","simon04","neilkennedy","byzyk","EugeneHlushko","chenxsan"],"related":[{"title":"Building Source Maps","url":"https://survivejs.com/webpack/building/source-maps/#-sourcemapdevtoolplugin-and-evalsourcemapdevtoolplugin-"}]},{"path":"src/content/plugins/split-chunks-plugin.mdx","name":"split-chunks-plugin.mdx","size":21411,"type":"file","extension":".mdx","url":"/plugins/split-chunks-plugin/","anchors":[{"title":"Defaults","id":"defaults","level":2},{"title":"Configuration","id":"configuration","level":2},{"title":"optimization.splitChunks","id":"optimizationsplitchunks","level":2},{"title":"splitChunks.automaticNameDelimiter","id":"splitchunksautomaticnamedelimiter","level":3},{"title":"splitChunks.chunks","id":"splitchunkschunks","level":3},{"title":"splitChunks.maxAsyncRequests","id":"splitchunksmaxasyncrequests","level":3},{"title":"splitChunks.maxInitialRequests","id":"splitchunksmaxinitialrequests","level":3},{"title":"splitChunks.defaultSizeTypes","id":"splitchunksdefaultsizetypes","level":3},{"title":"splitChunks.minChunks","id":"splitchunksminchunks","level":3},{"title":"splitChunks.hidePathInfo","id":"splitchunkshidepathinfo","level":3},{"title":"splitChunks.minSize","id":"splitchunksminsize","level":3},{"title":"splitChunks.minSizeReduction","id":"splitchunksminsizereduction","level":3},{"title":"splitChunks.enforceSizeThreshold","id":"splitchunksenforcesizethreshold","level":3},{"title":"splitChunks.minRemainingSize","id":"splitchunksminremainingsize","level":3},{"title":"splitChunks.layer","id":"splitchunkslayer","level":3},{"title":"splitChunks.maxSize","id":"splitchunksmaxsize","level":3},{"title":"splitChunks.maxAsyncSize","id":"splitchunksmaxasyncsize","level":3},{"title":"splitChunks.maxInitialSize","id":"splitchunksmaxinitialsize","level":3},{"title":"splitChunks.name","id":"splitchunksname","level":3},{"title":"splitChunks.usedExports","id":"splitchunksusedexports","level":3},{"title":"splitChunks.cacheGroups","id":"splitchunkscachegroups","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Defaults: Example 1","id":"defaults-example-1","level":3},{"title":"Defaults: Example 2","id":"defaults-example-2","level":3},{"title":"Split Chunks: Example 1","id":"split-chunks-example-1","level":3},{"title":"Split Chunks: Example 2","id":"split-chunks-example-2","level":3},{"title":"Split Chunks: Example 3","id":"split-chunks-example-3","level":3}],"title":"SplitChunksPlugin","group":"webpack","contributors":["sokra","jeremenichelli","Priestch","chrisdothtml","EugeneHlushko","byzyk","jacobangel","madhavarshney","sakhisheikh","superburrito","ryandrew14","snitin315","chenxsan","rohrlaf","jamesgeorge007","anshumanv","snitin315"],"related":[{"title":"webpack\'s automatic deduplication algorithm example","url":"https://github.com/webpack/webpack/blob/master/examples/many-pages/README.md"},{"title":"webpack 4: Code Splitting, chunk graph and the splitChunks optimization","url":"https://medium.com/webpack/webpack-4-code-splitting-chunk-graph-and-the-splitchunks-optimization-be739a861366"}]},{"path":"src/content/plugins/watch-ignore-plugin.mdx","name":"watch-ignore-plugin.mdx","size":552,"type":"file","extension":".mdx","url":"/plugins/watch-ignore-plugin/","anchors":[{"title":"Options","id":"options","level":2}],"title":"WatchIgnorePlugin","group":"webpack","contributors":["skipjack","byzyk","EugeneHlushko"]},{"path":"src/content/plugins/_compression-webpack-plugin.mdx","name":"compression-webpack-plugin.mdx","size":11805,"type":"file","extension":".mdx","url":"/plugins/compression-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"test","id":"test","level":3},{"title":"include","id":"include","level":3},{"title":"exclude","id":"exclude","level":3},{"title":"algorithm","id":"algorithm","level":3},{"title":"compressionOptions","id":"compressionoptions","level":3},{"title":"threshold","id":"threshold","level":3},{"title":"minRatio","id":"minratio","level":3},{"title":"filename","id":"filename","level":3},{"title":"deleteOriginalAssets","id":"deleteoriginalassets","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Using Zopfli","id":"using-zopfli","level":3},{"title":"Using Brotli","id":"using-brotli","level":3},{"title":"Multiple compressed versions of assets for different algorithm","id":"multiple-compressed-versions-of-assets-for-different-algorithm","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"CompressionWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/compression-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/compression-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/compression-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_copy-webpack-plugin.mdx","name":"copy-webpack-plugin.mdx","size":27639,"type":"file","extension":".mdx","url":"/plugins/copy-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"Patterns","id":"patterns","level":3},{"title":"noErrorOnMissing","id":"noerroronmissing","level":3},{"title":"Options","id":"options-1","level":3},{"title":"Examples","id":"examples","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"CopyWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/copy-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/copy-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/copy-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_css-minimizer-webpack-plugin.mdx","name":"css-minimizer-webpack-plugin.mdx","size":16599,"type":"file","extension":".mdx","url":"/plugins/css-minimizer-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Note about source maps","id":"note-about-source-maps","level":2},{"title":"Options","id":"options","level":2},{"title":"test","id":"test","level":3},{"title":"include","id":"include","level":3},{"title":"exclude","id":"exclude","level":3},{"title":"parallel","id":"parallel","level":3},{"title":"minify","id":"minify","level":3},{"title":"minimizerOptions","id":"minimizeroptions","level":3},{"title":"warningsFilter","id":"warningsfilter","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Use sourcemaps","id":"use-sourcemaps","level":3},{"title":"Remove all comments","id":"remove-all-comments","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"CssMinimizerWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/css-minimizer-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/css-minimizer-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/css-minimizer-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_eslint-webpack-plugin.mdx","name":"eslint-webpack-plugin.mdx","size":7728,"type":"file","extension":".mdx","url":"/plugins/eslint-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"cache","id":"cache","level":3},{"title":"cacheLocation","id":"cachelocation","level":3},{"title":"context","id":"context","level":3},{"title":"eslintPath","id":"eslintpath","level":3},{"title":"extensions","id":"extensions","level":3},{"title":"exclude","id":"exclude","level":3},{"title":"resourceQueryExclude","id":"resourcequeryexclude","level":3},{"title":"files","id":"files","level":3},{"title":"fix","id":"fix","level":3},{"title":"formatter","id":"formatter","level":3},{"title":"lintDirtyModulesOnly","id":"lintdirtymodulesonly","level":3},{"title":"threads","id":"threads","level":3},{"title":"Errors and Warning","id":"errors-and-warning","level":3},{"title":"Changelog","id":"changelog","level":2},{"title":"License","id":"license","level":2}],"title":"EslintWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/eslint-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/eslint-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/eslint-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_html-minimizer-webpack-plugin.mdx","name":"html-minimizer-webpack-plugin.mdx","size":15233,"type":"file","extension":".mdx","url":"/plugins/html-minimizer-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"test","id":"test","level":3},{"title":"include","id":"include","level":3},{"title":"exclude","id":"exclude","level":3},{"title":"parallel","id":"parallel","level":3},{"title":"minify","id":"minify","level":3},{"title":"minimizerOptions","id":"minimizeroptions","level":3},{"title":"Examples","id":"examples","level":2},{"title":"swc/html","id":"swchtml","level":3},{"title":"@minify-html/node","id":"minify-htmlnode","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"HtmlMinimizerWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/html-minimizer-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/html-minimizer-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/html-minimizer-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_image-minimizer-webpack-plugin.mdx","name":"image-minimizer-webpack-plugin.mdx","size":63294,"type":"file","extension":".mdx","url":"/plugins/image-minimizer-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Install optimize/generate tool","id":"install-optimizegenerate-tool","level":3},{"title":"Advanced setup","id":"advanced-setup","level":3},{"title":"Plugin Options","id":"plugin-options","level":2},{"title":"test","id":"test","level":3},{"title":"include","id":"include","level":3},{"title":"exclude","id":"exclude","level":3},{"title":"minimizer","id":"minimizer","level":3},{"title":"generator","id":"generator","level":3},{"title":"severityError","id":"severityerror","level":3},{"title":"loader","id":"loader","level":3},{"title":"concurrency","id":"concurrency","level":3},{"title":"deleteOriginalAssets","id":"deleteoriginalassets","level":3},{"title":"Loader Options","id":"loader-options","level":2},{"title":"minimizer","id":"minimizer-1","level":3},{"title":"generator","id":"generator-1","level":3},{"title":"severityError","id":"severityerror-1","level":3},{"title":"Additional API","id":"additional-api","level":2},{"title":"imageminNormalizeConfig(config)","id":"imageminnormalizeconfigconfig","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Optimize images based on size","id":"optimize-images-based-on-size","level":3},{"title":"Optimize and generate webp images","id":"optimize-and-generate-webp-images","level":3},{"title":"Generate webp images from copied assets","id":"generate-webp-images-from-copied-assets","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"ImageMinimizerWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/image-minimizer-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/image-minimizer-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/image-minimizer-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_install-webpack-plugin.mdx","name":"install-webpack-plugin.mdx","size":5303,"type":"file","extension":".mdx","url":"/plugins/install-webpack-plugin/","anchors":[{"title":"Usage","id":"usage","level":1},{"title":"Options","id":"options","level":1},{"title":"dependencies","id":"dependencies","level":2},{"title":"peer","id":"peer","level":3},{"title":"packageManager","id":"packagemanager","level":2},{"title":"type","id":"type","level":3},{"title":"options","id":"options-1","level":3},{"title":"arguments","id":"arguments","level":3},{"title":"dev","id":"dev","level":3},{"title":"quiet","id":"quiet","level":3},{"title":"prompt","id":"prompt","level":2},{"title":"Demo","id":"demo","level":1},{"title":"Features","id":"features","level":1},{"title":"Contributing","id":"contributing","level":2}],"title":"InstallWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/install-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/install-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/install-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_json-minimizer-webpack-plugin.mdx","name":"json-minimizer-webpack-plugin.mdx","size":4876,"type":"file","extension":".mdx","url":"/plugins/json-minimizer-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"test","id":"test","level":3},{"title":"include","id":"include","level":3},{"title":"exclude","id":"exclude","level":3},{"title":"minimizerOptions","id":"minimizeroptions","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"JsonMinimizerWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/json-minimizer-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/json-minimizer-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/json-minimizer-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_mini-css-extract-plugin.mdx","name":"mini-css-extract-plugin.mdx","size":29667,"type":"file","extension":".mdx","url":"/plugins/mini-css-extract-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"Plugin Options","id":"plugin-options","level":3},{"title":"Loader Options","id":"loader-options","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Recommended","id":"recommended","level":3},{"title":"Minimal example","id":"minimal-example","level":3},{"title":"Named export for CSS Modules","id":"named-export-for-css-modules","level":3},{"title":"The publicPath option as function","id":"the-publicpath-option-as-function","level":3},{"title":"Advanced configuration example","id":"advanced-configuration-example","level":3},{"title":"Hot Module Reloading (HMR)","id":"hot-module-reloading-hmr","level":3},{"title":"Minimizing For Production","id":"minimizing-for-production","level":3},{"title":"Using preloaded or inlined CSS","id":"using-preloaded-or-inlined-css","level":3},{"title":"Extracting all CSS in a single file","id":"extracting-all-css-in-a-single-file","level":3},{"title":"Extracting CSS based on entry","id":"extracting-css-based-on-entry","level":3},{"title":"Filename Option as function","id":"filename-option-as-function","level":3},{"title":"Long Term Caching","id":"long-term-caching","level":3},{"title":"Remove Order Warnings","id":"remove-order-warnings","level":3},{"title":"Multiple Themes","id":"multiple-themes","level":3},{"title":"Media Query Plugin","id":"media-query-plugin","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"MiniCssExtractPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/mini-css-extract-plugin/master/README.md","edit":"https://github.com/webpack-contrib/mini-css-extract-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/mini-css-extract-plugin","thirdParty":true},{"path":"src/content/plugins/_stylelint-webpack-plugin.mdx","name":"stylelint-webpack-plugin.mdx","size":7601,"type":"file","extension":".mdx","url":"/plugins/stylelint-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"cache","id":"cache","level":3},{"title":"cacheLocation","id":"cachelocation","level":3},{"title":"configFile","id":"configfile","level":3},{"title":"context","id":"context","level":3},{"title":"exclude","id":"exclude","level":3},{"title":"extensions","id":"extensions","level":3},{"title":"files","id":"files","level":3},{"title":"fix","id":"fix","level":3},{"title":"formatter","id":"formatter","level":3},{"title":"lintDirtyModulesOnly","id":"lintdirtymodulesonly","level":3},{"title":"stylelintPath","id":"stylelintpath","level":3},{"title":"threads","id":"threads","level":3},{"title":"Errors and Warning","id":"errors-and-warning","level":3},{"title":"Changelog","id":"changelog","level":2},{"title":"License","id":"license","level":2}],"title":"StylelintWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/stylelint-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/stylelint-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/stylelint-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_terser-webpack-plugin.mdx","name":"terser-webpack-plugin.mdx","size":21559,"type":"file","extension":".mdx","url":"/plugins/terser-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Note about source maps","id":"note-about-source-maps","level":2},{"title":"Options","id":"options","level":2},{"title":"test","id":"test","level":3},{"title":"include","id":"include","level":3},{"title":"exclude","id":"exclude","level":3},{"title":"parallel","id":"parallel","level":3},{"title":"minify","id":"minify","level":3},{"title":"terserOptions","id":"terseroptions","level":3},{"title":"extractComments","id":"extractcomments","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Preserve Comments","id":"preserve-comments","level":3},{"title":"Remove Comments","id":"remove-comments","level":3},{"title":"Custom Minify Function","id":"custom-minify-function","level":3},{"title":"Typescript","id":"typescript","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"TerserWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/terser-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/terser-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/terser-webpack-plugin","thirdParty":true}],"size":324359,"type":"directory","url":"/plugins/"},{"path":"src/content/index.mdx","name":"index.mdx","size":940,"type":"file","extension":".mdx","url":"/","anchors":[{"title":"Write Your Code","id":"write-your-code","level":2},{"title":"Bundle It","id":"bundle-it","level":2},{"title":"Awesome isn\'t it? Let\'s dive in!","id":"awesome-isnt-it-lets-dive-in","level":2}],"title":"webpack","sort":-1},{"path":"src/content/comparison.mdx","name":"comparison.mdx","size":18878,"type":"file","extension":".mdx","url":"/comparison/","anchors":[{"title":"Bundling vs. Loading","id":"bundling-vs-loading","level":2}],"title":"Comparison","sort":1,"contributors":["pksjce","bebraw","chrisVillanueva","tashian","simon04","byzyk"],"related":[{"title":"JSPM vs. webpack","url":"https://ilikekillnerds.com/2015/07/jspm-vs-webpack/"},{"title":"webpack vs. Browserify vs. SystemJS","url":"https://engineering.velocityapp.com/webpack-vs-browersify-vs-systemjs-for-spas-95b349a41fa0"}]},{"path":"src/content/awesome-webpack.mdx","name":"awesome-webpack.mdx","size":43053,"type":"file","extension":".mdx","url":"/awesome-webpack/","anchors":[{"title":"Webpack Ecosystem","id":"webpack-ecosystem","level":2},{"title":"Support Webpack","id":"support-webpack","level":3},{"title":"Community","id":"community","level":3},{"title":"Twitter","id":"twitter","level":3},{"title":"Libraries","id":"libraries","level":2},{"title":"Loaders","id":"loaders","level":3},{"title":"Integration Libraries","id":"integration-libraries","level":3},{"title":"Webpack Plugins","id":"webpack-plugins","level":3},{"title":"Webpack Tools","id":"webpack-tools","level":3},{"title":"Research & Training","id":"research--training","level":2},{"title":"Articles","id":"articles","level":3},{"title":"Videos","id":"videos","level":3},{"title":"Courses","id":"courses","level":3},{"title":"Books","id":"books","level":3},{"title":"Webpack Examples","id":"webpack-examples","level":3},{"title":"Community Examples","id":"community-examples","level":3},{"title":"Other","id":"other","level":3}],"title":"Awesome webpack","sort":2,"contributors":["snitin315","licg9999"]},{"path":"src/content/branding.mdx","name":"branding.mdx","size":5677,"type":"file","extension":".mdx","url":"/branding/","anchors":[{"title":"The Name","id":"the-name","level":2},{"title":"Logo","id":"logo","level":2},{"title":"Icon only","id":"icon-only","level":2},{"title":"Color Palette","id":"color-palette","level":2},{"title":"License","id":"license","level":2}],"title":"Branding Guidelines","sort":2,"contributors":["jhnns","skipjack","rouzbeh84","byzyk"]},{"path":"src/content/glossary.mdx","name":"glossary.mdx","size":5804,"type":"file","extension":".mdx","url":"/glossary/","anchors":[{"title":"A","id":"a","level":2},{"title":"B","id":"b","level":2},{"title":"C","id":"c","level":2},{"title":"D","id":"d","level":2},{"title":"E","id":"e","level":2},{"title":"H","id":"h","level":2},{"title":"L","id":"l","level":2},{"title":"M","id":"m","level":2},{"title":"O","id":"o","level":2},{"title":"P","id":"p","level":2},{"title":"R","id":"r","level":2},{"title":"S","id":"s","level":2},{"title":"T","id":"t","level":2},{"title":"V","id":"v","level":2},{"title":"W","id":"w","level":2}],"title":"Glossary","sort":3,"contributors":["kryptokinght","rouzbeh84","bebraw","skipjack","byzyk","pranshuchittora","jamesgeorge007"]},{"path":"src/content/license.mdx","name":"license.mdx","size":772,"type":"file","extension":".mdx","url":"/license/","anchors":[{"title":"webpack","id":"webpack","level":2},{"title":"webpack logo and icon","id":"webpack-logo-and-icon","level":2},{"title":"webpack documentation","id":"webpack-documentation","level":2},{"title":"webpack code samples","id":"webpack-code-samples","level":2}],"title":"License","sort":5,"contributors":["EugeneHlushko","pranshuchittora"]}],"size":1667429,"type":"directory","url":"/"}');const mt={Badge:nt,StackBlitzPreview:ot,a:at};function ht(e){const t=(0,s.TH)(),l=(0,s.s0)(),[n,o]=(0,r.useState)(!1),a=()=>{o(!n)},c=e=>{let t=e.findIndex((e=>"index.mdx"===e.name.toLowerCase()));return-1!==t&&(e.unshift(e[t]),e.splice(t+1,1)),e.map((e=>{let{title:t,name:i,url:l,group:n,sort:s,anchors:o,children:a}=e;return{title:t||i,content:t||i,url:l,group:n,sort:s,anchors:o,children:a?c(a):[]}})).filter((e=>"printable.mdx"!==e.title&&!e.content.includes("Printable")))};(0,r.useEffect)((()=>{"serviceWorker"in navigator&&navigator.serviceWorker.addEventListener("controllerchange",(()=>{window.location.reload()}))}),[]),(0,r.useEffect)((()=>{b()&&"serviceWorker"in navigator&&i.e(3790).then(i.bind(i,3790)).then((e=>{let{Workbox:t}=e;const i=new t("/sw.js");i.addEventListener("waiting",(()=>{console.log("A new service worker has installed, but it can't activate until all tabs running the current version have been unloaded")})),i.register()}))}),[]);let p=ut.children.filter((e=>"directory"===e.type)),u=p.find((e=>{let{url:i}=e;return t.pathname.startsWith(i)})),v=h(ut).filter((e=>".md"===e.extension||".mdx"===e.extension));const x=c(u?u.children:ut.children.filter((e=>"directory"!==e.type&&"/"!==e.url))),k=["contribute","blog"],y=((e,t)=>{const i=g(e,(e=>e.url===t));return i?i?t.includes("/printable")?"Combined printable page | webpack":"/"===t?i.title||"webpack":`${i.title} | webpack`:void 0:"webpack"})(ut,t.pathname),w=((e,t)=>{const i=g(e,(e=>e.url===t));if(i)return t.includes("/printable")?"":i.description||""})(ut,t.pathname)||"webpack is a module bundler. Its main purpose is to bundle JavaScript files for usage in a browser, yet it is also capable of transforming, bundling, or packaging just about any resource or asset.";return(0,r.useEffect)((()=>{const e=function(e){return!("/configuration/other-options/"!==e.pathname||!e.hash.startsWith("#cache"))&&`/configuration/cache/${e.hash}`}(t);e&&l(e,{replace:!0})}),[t,l]),(0,d.jsx)(m.Zo,{components:mt,children:(0,d.jsxs)("div",{className:"site",children:[(0,d.jsxs)(rt.ql,{children:[(0,d.jsx)("html",{lang:"en"}),(0,d.jsx)("meta",{charset:"utf-8"}),(0,d.jsx)("meta",{name:"theme-color",content:"#2B3A42"}),(0,d.jsx)("meta",{name:"viewport",content:"width=device-width, initial-scale=1"}),function(e){return e.includes("/printable")}(t.pathname)?(0,d.jsx)("meta",{name:"robots",content:"noindex,nofollow"}):null,(0,d.jsx)("title",{children:y}),(0,d.jsx)("meta",{name:"description",content:w}),(0,d.jsx)("meta",{property:"og:site_name",content:"webpack"}),(0,d.jsx)("meta",{property:"og:type",content:"website"}),(0,d.jsx)("meta",{property:"og:title",content:y}),(0,d.jsx)("meta",{property:"og:description",name:"description",content:w}),(0,d.jsx)("meta",{property:"og:image",content:`https://webpack.js.org${pt}`}),(0,d.jsx)("meta",{property:"twitter:card",content:"summary"}),(0,d.jsx)("meta",{property:"twitter:site",content:"@webpack"}),(0,d.jsx)("meta",{property:"twitter:creator",content:"@webpack"}),(0,d.jsx)("meta",{property:"twitter:domain",content:"https://webpack.js.org/"}),(0,d.jsx)("link",{rel:"icon",type:"image/x-icon",href:dt}),(0,d.jsx)("link",{rel:"manifest",href:"/manifest.json"}),(0,d.jsx)("link",{rel:"canonical",href:`https://webpack.js.org${function(e){return e.replace(/\/?$/,"/")}(t.pathname)}`}),(0,d.jsx)("meta",{name:"mobile-web-app-capable",content:"yes"}),(0,d.jsx)("link",{rel:"icon",sizes:"192x192",href:"/icon_192x192.png"}),(0,d.jsx)("link",{rel:"icon",sizes:"512x512",href:"/icon_512x512.png"}),(0,d.jsx)("meta",{name:"apple-mobile-web-app-capable",content:"yes"}),(0,d.jsx)("meta",{name:"apple-mobile-web-app-status-bar-style",content:"black"}),(0,d.jsx)("meta",{name:"apple-mobile-web-app-title",content:"webpack"}),(0,d.jsx)("link",{rel:"apple-touch-icon",href:"/icon_180x180.png"}),(0,d.jsx)("link",{rel:"mask-icon",href:ct,color:"#465e69"}),(0,d.jsx)("meta",{name:"msapplication-TileImage",content:"/icon_150x150.png"}),(0,d.jsx)("meta",{name:"msapplication-TileColor",content:"#465e69"})]}),(0,d.jsx)("div",{className:"site__header",children:(0,d.jsx)(V,{pathname:t.pathname,hash:t.hash,toggleSidebar:a,links:[{content:"Documentation",url:"/concepts/",isactive:(e,t)=>/^\/(api|concepts|configuration|guides|loaders|migrate|plugins)/.test(t.pathname),children:c(p.filter((e=>{let{name:t}=e;return!1===k.includes(t)})))},{content:"Contribute",url:"/contribute/"},{content:"Blog",url:"/blog/"}]})}),b()?(0,d.jsx)(Z,{isOpen:n,sections:c(ut.children),toggle:a}):null,(0,d.jsxs)(s.Z5,{children:[(0,d.jsx)(s.AW,{index:!0,element:(0,d.jsx)(he,{})}),(0,d.jsxs)(s.AW,{element:(0,d.jsx)(Y,{className:"site__content",children:(0,d.jsx)(s.j3,{})}),children:[(0,d.jsx)(s.AW,{path:"app-shell",element:(0,d.jsx)(r.Fragment,{})}),v.map((i=>{let l=i.path.replace("src/content/","");const{previous:n,next:o}=function(e,t,i="url"){let l,n;const s=e.findIndex((e=>e[i]===t[i]));return-1!==s&&(l=e[s-1],n=e[s+1]),{previous:l,next:n}}(x,i,"url");return(0,d.jsx)(s.AW,{path:i.url,element:(0,d.jsx)(vt,{currentPage:t.pathname,sidebarPages:x,page:i,next:o,previous:n,import:e.import,path:l})},i.url)})),(0,d.jsx)(s.AW,{path:"*",element:(0,d.jsx)(lt,{})})]})]}),(0,d.jsx)(We,{}),(0,d.jsx)(f.ZP,{})]})})}ht.propTypes={import:a().func};var gt=ht;function vt(e){const{currentPage:t,sidebarPages:i,page:l,previous:n,next:s}=e,o=e.import(e.path);return(0,d.jsxs)(r.Fragment,{children:[(0,d.jsx)(be,{}),(0,d.jsx)(Ie,{className:"site__sidebar",currentPage:t,pages:i}),(0,d.jsx)(it,{...l,content:o,previous:n,next:s})]})}function bt(){return(0,d.jsx)(gt,{import:e=>i(7755)(`./${e}`)})}vt.propTypes={currentPage:a().string,sidebarPages:a().array,previous:a().object,next:a().object,page:a().object,import:a().func,path:a().string};const ft=c,xt=l.hydrate;b()&&xt((0,d.jsx)(ft,{id:"UA-46921629-2",children:(0,d.jsx)(rt.B6,{children:(0,d.jsx)(bt,{})})}),document.getElementById("root"))},7338:function(e){const t=void 0!==window&&void 0!==window.document;e.exports=t},833:function(e){e.exports=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];if(0===e.length)return;let t=99;for(const i of e)i.level2&&void 0!==arguments[2]?arguments[2]:l(i);if(0===i.length)return[];if(i.length>0){const s=[];return i.forEach((e=>{e.level===n?s.push([e]):s[s.length-1].push(e)})),s.map((i=>{if(i.length>1){const[n,...s]=i;return{...n,title2:n.title.replace(new RegExp(`^${t}\\.`,"i"),""),children:e(n.title,s,l(s))}}return{...i[0],title2:i[0].title.replace(new RegExp(`^${t}\\.`,"i"),"")}}))}}},7268:function(e){e.exports=function(){const e="localStorageTest";try{localStorage.setItem(e,e),localStorage.removeItem(e)}catch(e){return!1}}},7755:function(e,t,i){var l={"./api/cli.mdx":[8493,8493],"./api/compilation-hooks.mdx":[2433,2433],"./api/compilation-object.mdx":[388,388],"./api/compiler-hooks.mdx":[4951,4951],"./api/contextmodulefactory-hooks.mdx":[9806,9806],"./api/hot-module-replacement.mdx":[1567,1567],"./api/index.mdx":[9317,9317],"./api/loaders.mdx":[5773,5773],"./api/logging.mdx":[8197,8197],"./api/module-methods.mdx":[5229,5229],"./api/module-variables.mdx":[1903,1903],"./api/node.mdx":[1126,1126],"./api/normalmodulefactory-hooks.mdx":[1280,1280],"./api/parser.mdx":[8925,8925],"./api/plugins.mdx":[5389,5389],"./api/resolvers.mdx":[4612,4612],"./api/stats.mdx":[9614,9614],"./api/webpack-dev-server.mdx":[5322,5322],"./awesome-webpack.mdx":[7706,7706],"./blog/2020-10-10-webpack-5-release.mdx":[1701,1701],"./blog/2020-12-08-roadmap-2021.mdx":[6638,6638],"./blog/index.mdx":[4616,4616],"./branding.mdx":[9966,9966],"./comparison.mdx":[869,869],"./concepts/configuration.mdx":[345,345],"./concepts/dependency-graph.mdx":[7154,7154],"./concepts/entry-points.mdx":[8597,8597],"./concepts/hot-module-replacement.mdx":[158,158],"./concepts/index.mdx":[7081,7081],"./concepts/loaders.mdx":[8509,8509],"./concepts/manifest.mdx":[5485,5485],"./concepts/module-federation.mdx":[7750,7750],"./concepts/module-resolution.mdx":[1721,1721],"./concepts/modules.mdx":[3662,3662],"./concepts/output.mdx":[4401,4401],"./concepts/plugins.mdx":[6611,6611],"./concepts/targets.mdx":[2395,2395],"./concepts/under-the-hood.mdx":[2437,2437],"./concepts/why-webpack.mdx":[1454,1454],"./configuration/cache.mdx":[6822,6822],"./configuration/configuration-languages.mdx":[4673,4673],"./configuration/configuration-types.mdx":[7801,2068],"./configuration/dev-server.mdx":[6415,6415],"./configuration/devtool.mdx":[7474,7474],"./configuration/entry-context.mdx":[9003,9003],"./configuration/experiments.mdx":[734,734],"./configuration/extending-configurations.mdx":[6965,6965],"./configuration/externals.mdx":[5030,5030],"./configuration/index.mdx":[5902,5902],"./configuration/mode.mdx":[4928,4928],"./configuration/module.mdx":[4409,4409],"./configuration/node.mdx":[1789,1789],"./configuration/optimization.mdx":[8624,8624],"./configuration/other-options.mdx":[8641,8641],"./configuration/output.mdx":[5687,5687],"./configuration/performance.mdx":[9662,9662],"./configuration/plugins.mdx":[2562,2562],"./configuration/resolve.mdx":[7067,7067],"./configuration/stats.mdx":[22,22],"./configuration/target.mdx":[1286,1286],"./configuration/watch.mdx":[2459,2459],"./contribute/debugging.mdx":[4592,4592],"./contribute/index.mdx":[6949,6949],"./contribute/plugin-patterns.mdx":[2699,2699],"./contribute/release-process.mdx":[4385,4385],"./contribute/writers-guide.mdx":[8301,8301],"./contribute/writing-a-loader.mdx":[242,242],"./contribute/writing-a-plugin.mdx":[1227,1227],"./glossary.mdx":[7940,7940],"./guides/asset-management.mdx":[9097,9097],"./guides/asset-modules.mdx":[6295,6295],"./guides/author-libraries.mdx":[783,783],"./guides/build-performance.mdx":[6231,6231],"./guides/caching.mdx":[2570,2570],"./guides/code-splitting.mdx":[596,596],"./guides/csp.mdx":[3139,3139],"./guides/dependency-management.mdx":[3529,3529],"./guides/development-vagrant.mdx":[3575,3575],"./guides/development.mdx":[6945,6945],"./guides/ecma-script-modules.mdx":[9744,9744],"./guides/entry-advanced.mdx":[2715,2715],"./guides/environment-variables.mdx":[1955,1955],"./guides/getting-started.mdx":[4364,4364],"./guides/hot-module-replacement.mdx":[5554,5554],"./guides/index.mdx":[3295,3295],"./guides/installation.mdx":[8972,8972],"./guides/integrations.mdx":[3849,3849],"./guides/lazy-loading.mdx":[6002,6002],"./guides/output-management.mdx":[5592,5592],"./guides/package-exports.mdx":[1853,1853],"./guides/production.mdx":[3510,3510],"./guides/progressive-web-application.mdx":[1062,1062],"./guides/public-path.mdx":[3781,3781],"./guides/shimming.mdx":[8937,8937],"./guides/tree-shaking.mdx":[9970,9970],"./guides/typescript.mdx":[4168,4168],"./guides/web-workers.mdx":[6006,6006],"./index.mdx":[1975],"./license.mdx":[7047,7047],"./loaders/_babel-loader.mdx":[8321,8321],"./loaders/_coffee-loader.mdx":[1576,1576],"./loaders/_css-loader.mdx":[1736,1736],"./loaders/_exports-loader.mdx":[1693,1693],"./loaders/_expose-loader.mdx":[9922,9922],"./loaders/_html-loader.mdx":[6364,6364],"./loaders/_imports-loader.mdx":[5052,5052],"./loaders/_less-loader.mdx":[5779,5779],"./loaders/_node-loader.mdx":[86,86],"./loaders/_postcss-loader.mdx":[1665,1665],"./loaders/_remark-loader.mdx":[6393,6393],"./loaders/_sass-loader.mdx":[2154,2154],"./loaders/_source-map-loader.mdx":[9749,9749],"./loaders/_style-loader.mdx":[8365,8365],"./loaders/_stylus-loader.mdx":[2537,7801],"./loaders/_thread-loader.mdx":[1880,1880],"./loaders/_val-loader.mdx":[7203,7203],"./loaders/index.mdx":[7695,7695],"./migrate/3.mdx":[3807,3807],"./migrate/4.mdx":[9470,9470],"./migrate/5.mdx":[5521,5521],"./migrate/index.mdx":[9412,9412],"./plugins/NoEmitOnErrorsPlugin.mdx":[3311,3311],"./plugins/_compression-webpack-plugin.mdx":[3557,3557],"./plugins/_copy-webpack-plugin.mdx":[2027,2027],"./plugins/_css-minimizer-webpack-plugin.mdx":[4489,4489],"./plugins/_eslint-webpack-plugin.mdx":[482,482],"./plugins/_html-minimizer-webpack-plugin.mdx":[436,436],"./plugins/_image-minimizer-webpack-plugin.mdx":[5084,5084],"./plugins/_install-webpack-plugin.mdx":[5586,5586],"./plugins/_json-minimizer-webpack-plugin.mdx":[9439,9439],"./plugins/_mini-css-extract-plugin.mdx":[6640,6640],"./plugins/_stylelint-webpack-plugin.mdx":[7140,7140],"./plugins/_svg-chunk-webpack-plugin.mdx":[7636,7636],"./plugins/_terser-webpack-plugin.mdx":[1883,1883],"./plugins/automatic-prefetch-plugin.mdx":[1710,1710],"./plugins/banner-plugin.mdx":[7036,7036],"./plugins/commons-chunk-plugin.mdx":[4914,4914],"./plugins/context-exclusion-plugin.mdx":[8832,8832],"./plugins/context-replacement-plugin.mdx":[4212,4212],"./plugins/define-plugin.mdx":[1417,1417],"./plugins/dll-plugin.mdx":[5990,5990],"./plugins/environment-plugin.mdx":[7224,7224],"./plugins/eval-source-map-dev-tool-plugin.mdx":[4628,4628],"./plugins/hashed-module-ids-plugin.mdx":[486,486],"./plugins/hot-module-replacement-plugin.mdx":[2098,2098],"./plugins/html-webpack-plugin.mdx":[6852,6852],"./plugins/ignore-plugin.mdx":[38,38],"./plugins/index.mdx":[4866,4866],"./plugins/internal-plugins.mdx":[8178,8178],"./plugins/limit-chunk-count-plugin.mdx":[8366,8366],"./plugins/min-chunk-size-plugin.mdx":[9925,9925],"./plugins/module-concatenation-plugin.mdx":[2760,2760],"./plugins/module-federation-plugin.mdx":[2877,2877],"./plugins/normal-module-replacement-plugin.mdx":[2338,2338],"./plugins/prefetch-plugin.mdx":[3191,3191],"./plugins/profiling-plugin.mdx":[2355,2355],"./plugins/progress-plugin.mdx":[7849,7849],"./plugins/provide-plugin.mdx":[672,672],"./plugins/source-map-dev-tool-plugin.mdx":[7684,7684],"./plugins/split-chunks-plugin.mdx":[9529,9529],"./plugins/watch-ignore-plugin.mdx":[8664,8664]};function n(e){if(!i.o(l,e))return Promise.resolve().then((function(){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}));var t=l[e],n=t[0];return Promise.all(t.slice(1).map(i.e)).then((function(){return i(n)}))}n.keys=function(){return Object.keys(l)},n.id=7755,e.exports=n},2807:function(e,t,i){"use strict";e.exports=i.p+"icon-square-small-slack.1c7f4f7a52c41f94.png"}},s={};function o(e){var t=s[e];if(void 0!==t)return t.exports;var i=s[e]={id:e,loaded:!1,exports:{}};return n[e].call(i.exports,i,i.exports,o),i.loaded=!0,i.exports}o.m=n,e=[],o.O=function(t,i,l,n){if(!i){var s=1/0;for(c=0;c=n)&&Object.keys(o.O).every((function(e){return o.O[e](i[r])}))?i.splice(r--,1):(a=!1,n0&&e[c-1][2]>n;c--)e[c]=e[c-1];e[c]=[i,l,n]},o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,{a:t}),t},i=Object.getPrototypeOf?function(e){return Object.getPrototypeOf(e)}:function(e){return e.__proto__},o.t=function(e,l){if(1&l&&(e=this(e)),8&l)return e;if("object"==typeof e&&e){if(4&l&&e.__esModule)return e;if(16&l&&"function"==typeof e.then)return e}var n=Object.create(null);o.r(n);var s={};t=t||[null,i({}),i([]),i(i)];for(var a=2&l&&e;"object"==typeof a&&!~t.indexOf(a);a=i(a))Object.getOwnPropertyNames(a).forEach((function(t){s[t]=function(){return e[t]}}));return s.default=function(){return e},o.d(n,s),n},o.d=function(e,t){for(var i in t)o.o(t,i)&&!o.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},o.f={},o.e=function(e){return Promise.all(Object.keys(o.f).reduce((function(t,i){return o.f[i](e,t),t}),[]))},o.u=function(e){return e+"."+{22:"0bad52954cb1e535",38:"e41ef84c9f39a001",86:"798417f717f86ccf",158:"d3a8b05ab5eba34f",242:"ab10ab7c1dd76981",345:"9125a841e4d2a69b",388:"5e365f623a577b20",436:"effec7f1a6cd3f7c",482:"fb2f5c5690f2ede6",486:"07eea4c8e398ceaa",596:"de1fc8e89d1d0054",672:"33a05dec2644a3f2",734:"ef3ca96602fb1b36",783:"744dc2e0dbfa8f1e",869:"061b7b19fe192d7c",1062:"4b4a6442fe45bf9b",1126:"34ecbee20d75652e",1227:"4dd7e385946056e3",1280:"ca77f17769a1fe4e",1286:"5649293f903c744c",1360:"3c741048a0d3e046",1417:"2f8c67acd805e5a3",1454:"5a7c23e574f94322",1567:"ad0b41ed522166c6",1576:"41232090156c81b9",1665:"d8663b24781bbe67",1693:"52992d55c841c5b1",1701:"75a769d0d5bf3a68",1710:"a08b5eff539700ec",1721:"61e09c64706ccef2",1736:"3d5a6c937c98715e",1789:"43aeeae7733fb125",1853:"69cc4fcf0e934cda",1880:"6af612be186164fe",1883:"f4fbb18529b11868",1903:"82d0b4480a2c5038",1955:"4ca3f15610c41345",2027:"aa99215ab333639a",2068:"d8a07ebf1384b11f",2098:"4086d0614deb4bc3",2154:"0dfc8e89172c5e31",2338:"5125ff1542976e5b",2355:"e1aff2153b6603bb",2395:"1cc5a97825b30d7f",2433:"88ab42f4c72e9006",2437:"fde06a90084b2261",2459:"3d07df3f3b01a989",2562:"595a91fb8b0a83de",2570:"d7aaf2065d6061c3",2699:"9f054a024abea74b",2715:"4a78aad947bc8977",2760:"037d501d9f73c652",2877:"dae4e947f31ce809",3139:"4939482d29098ec4",3191:"82222249a6d51ee7",3295:"b887ad5c2e6198b9",3311:"d31770cad34ad2b8",3510:"1bb43fc88b3af023",3529:"ac8397f3631880f8",3557:"28ebc20129af05e8",3575:"13be42be98092ab4",3662:"01f120a0e9e04079",3781:"5270273165b136a8",3790:"5aaebcd7904c4130",3807:"b4ab89f55293feb9",3849:"b5b1078e8a6dbeea",4168:"cfbd5f90cc1a94c6",4212:"4a1cf37925dc91a3",4364:"2ec88ef1909289d9",4385:"c34e4ad461fdf005",4401:"602150ffe8747c75",4409:"7f309035adca33d9",4483:"b1dca0f86fb6b94a",4489:"d3832bba2c66c356",4592:"6aeb081ccbb7ad57",4612:"8c1244ae60e18043",4616:"18b505e4af620fdc",4628:"4a8df0149fa05674",4673:"ec17bf95d78ebe18",4866:"4a718a184bcdfb92",4914:"c30644d140a43cbf",4928:"4fac0a28d6febcdb",4951:"16978b849492c379",5030:"236972df8300dd08",5052:"dbaf5d7045d265e6",5084:"5697db566cee5aa8",5229:"0d9537c0b4424333",5322:"0e90c6d4e053509b",5389:"cccfd28e4c273336",5485:"8e7d453fdd3b839f",5521:"07f7edf67512dc6d",5554:"1fcfe31e22986204",5586:"11d9359dd74f5bdb",5592:"b0adab98810c0d97",5687:"f2fc5dd6dfcf9833",5773:"97779938b1cff19f",5779:"7dc2b73a690b3412",5902:"04710a0dd0dcc3ff",5990:"42fbea7ab2dd9537",6002:"8211e0cac546c008",6006:"b7e767f261aee1a9",6231:"e2cdde7213fd2271",6295:"bb4384df0fcba912",6364:"3ba9b11d6aed95f8",6393:"8be4b93597db826d",6415:"1d6e9d7c6f2615cf",6611:"f2a46b9cba680306",6638:"9c9636b4b7d069d8",6640:"b07704d9b272e1bc",6822:"a57cf61b6d0ffa1c",6852:"289a8c22b4857b2e",6945:"f1381c0b67a31547",6949:"bd404ee97e767c23",6965:"ef365dbc467507f8",7036:"375bb82829f91c11",7047:"396bef6aeb691c24",7067:"cb268bf99e1d99c4",7081:"5d74d5f525540796",7140:"43b99f9d9d019e60",7154:"f3ac387c19d800ee",7203:"8477f497f03de2c8",7224:"dfc04cf727de379a",7474:"f14d060f3e66f6fb",7636:"5b8ba386984e86d2",7684:"0c3f12933a0a746e",7695:"7b8750dbd0d81343",7706:"2cfc624922dd8e66",7750:"58576bd4203f2689",7801:"77dfea958490e14b",7849:"529ea11328581b55",7940:"93c658c9deeceacb",8178:"8880dd2787c1a656",8197:"f6c60f1fed359f4a",8301:"344706718b004ad8",8321:"c69085786c3a7fe3",8365:"35824892b9c4f79d",8366:"f1059a2785a4de8f",8493:"2d23a16998fc39b9",8509:"3681f6241da34855",8597:"20a72d6a3a9ee9b3",8624:"f8782d181726ba5e",8641:"06404db7c93760fa",8664:"d82df2bf521b320f",8832:"dd20a5ea95dacc98",8925:"8b996e4929f27ed5",8937:"0d7393e8b9338a00",8972:"80e3e466fef72ff7",9003:"31e799b11f09c97f",9097:"4e23fe8af21a373b",9317:"325355a99ad4b972",9412:"ac6e0846a1cc4438",9439:"c7e32579484000dc",9470:"f5b29d01261f171e",9514:"686c191d57965d19",9529:"db2b83f6aa465582",9614:"3ccf1fe3507c30fc",9662:"80294093518d02d4",9744:"157f51ec0a90a90a",9749:"c116f75e510ae890",9806:"cd32286980ff579a",9922:"589d0aa47821100e",9925:"1d9ff238b2beb027",9966:"3e32335fe844f02f",9970:"4312ad51b3195ba8"}[e]+".js"},o.miniCssF=function(e){return e+".aa5e42b4ace15744.css"},o.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},l={},o.l=function(e,t,i,n){if(l[e])l[e].push(t);else{var s,a;if(void 0!==i)for(var r=document.getElementsByTagName("script"),d=0;dn.createElement("svg",s({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"},e),l||(l=n.createElement("path",{d:"M14.3 14.8c-.4.5-1.2.5-1.6 0l-2.7-3-2.7 3a1.2 1.2 0 1 1-1.6-1.6L8.4 10 5.7 6.8a1.2 1.2 0 1 1 1.6-1.6l2.7 3 2.7-3a1.2 1.2 0 1 1 1.6 1.6L11.6 10l2.7 3.2c.5.4.5 1.2 0 1.6z"})))},1975:function(e,t,i){"use strict";i.r(t),i.d(t,{default:function(){return f}}),i(7378);var l=i(2682);function n(){return n=Object.assign?Object.assign.bind():function(e){for(var t=1;t")),"\n",(0,l.kt)("span",{className:"token tag",parentName:"code"},(0,l.kt)("span",{className:"token tag",parentName:"span"},(0,l.kt)("span",{className:"token punctuation",parentName:"span"},"<"),"html"),(0,l.kt)("span",{className:"token punctuation",parentName:"span"},">")),"\n ",(0,l.kt)("span",{className:"token tag",parentName:"code"},(0,l.kt)("span",{className:"token tag",parentName:"span"},(0,l.kt)("span",{className:"token punctuation",parentName:"span"},"<"),"head"),(0,l.kt)("span",{className:"token punctuation",parentName:"span"},">")),"\n ",(0,l.kt)("span",{className:"token tag",parentName:"code"},(0,l.kt)("span",{className:"token tag",parentName:"span"},(0,l.kt)("span",{className:"token punctuation",parentName:"span"},"<"),"meta")," ",(0,l.kt)("span",{className:"token attr-name",parentName:"span"},"charset"),(0,l.kt)("span",{className:"token attr-value",parentName:"span"},(0,l.kt)("span",{className:"token punctuation attr-equals",parentName:"span"},"="),(0,l.kt)("span",{className:"token punctuation",parentName:"span"},'"'),"utf-8",(0,l.kt)("span",{className:"token punctuation",parentName:"span"},'"'))," ",(0,l.kt)("span",{className:"token punctuation",parentName:"span"},"/>")),"\n ...\n ",(0,l.kt)("span",{className:"token tag",parentName:"code"},(0,l.kt)("span",{className:"token tag",parentName:"span"},(0,l.kt)("span",{className:"token punctuation",parentName:"span"},""),"head"),(0,l.kt)("span",{className:"token punctuation",parentName:"span"},">")),"\n ",(0,l.kt)("span",{className:"token tag",parentName:"code"},(0,l.kt)("span",{className:"token tag",parentName:"span"},(0,l.kt)("span",{className:"token punctuation",parentName:"span"},"<"),"body"),(0,l.kt)("span",{className:"token punctuation",parentName:"span"},">")),"\n ...\n ",(0,l.kt)("span",{className:"token tag",parentName:"code"},(0,l.kt)("span",{className:"token tag",parentName:"span"},(0,l.kt)("span",{className:"token punctuation",parentName:"span"},"<"),"script")," ",(0,l.kt)("span",{className:"token attr-name",parentName:"span"},"src"),(0,l.kt)("span",{className:"token attr-value",parentName:"span"},(0,l.kt)("span",{className:"token punctuation attr-equals",parentName:"span"},"="),(0,l.kt)("span",{className:"token punctuation",parentName:"span"},'"'),"dist/bundle.js",(0,l.kt)("span",{className:"token punctuation",parentName:"span"},'"')),(0,l.kt)("span",{className:"token punctuation",parentName:"span"},">")),(0,l.kt)("span",{className:"token script",parentName:"code"}),(0,l.kt)("span",{className:"token tag",parentName:"code"},(0,l.kt)("span",{className:"token tag",parentName:"span"},(0,l.kt)("span",{className:"token punctuation",parentName:"span"},""),"script"),(0,l.kt)("span",{className:"token punctuation",parentName:"span"},">")),"\n ",(0,l.kt)("span",{className:"token tag",parentName:"code"},(0,l.kt)("span",{className:"token tag",parentName:"span"},(0,l.kt)("span",{className:"token punctuation",parentName:"span"},""),"body"),(0,l.kt)("span",{className:"token punctuation",parentName:"span"},">")),"\n",(0,l.kt)("span",{className:"token tag",parentName:"code"},(0,l.kt)("span",{className:"token tag",parentName:"span"},(0,l.kt)("span",{className:"token punctuation",parentName:"span"},""),"html"),(0,l.kt)("span",{className:"token punctuation",parentName:"span"},">")))))}h.isMDXComponent=!0;var g=h;function v(){return v=Object.assign?Object.assign.bind():function(e){for(var t=1;tPromise.all([i.e(4483),i.e(9514)]).then(i.bind(i,9514)))),r="3",d=!1!==s()(),c=()=>!!d&&localStorage.getItem("notification-dismissed")===r;function p(){const[e,t]=(0,l.useState)(!0);return(0,l.useEffect)((()=>{t((()=>c()))}),[]),(0,o.jsx)(o.Fragment,{children:!1===e?(0,o.jsx)(l.Suspense,{fallback:(0,o.jsx)("div",{}),children:(0,o.jsx)(a,{onClose:()=>{t(!0)}})}):void 0})}},193:function(e){e.exports={body:'\n '}},3466:function(e,t,i){"use strict";var l=i(1542),n=i(5783),s=i(4935),o=i(3615),a=i.n(o),r=i(7378),d=i(4246);function c(e){const{id:t,set:i,children:l}=e;return(0,d.jsx)(n.VK,{children:(0,d.jsx)(u,{id:t,set:i,children:l})})}function p(e,t){if(!window.ga)throw new Error("Google analytics is not initialized");if("string"==typeof t){for(var i=arguments.length,l=new Array(i>2?i-2:0),n=2;n{!function(e,t){!window.ga&&e&&(window.ga=window.ga||function(){(ga.q=ga.q||[]).push(arguments)},ga.l=+new Date,function(){const e=document.createElement("script");e.async=!0,e.type="text/javascript",e.src="//www.google-analytics.com/analytics.js",document.getElementsByTagName("head")[0].appendChild(e)}(),window.ga("create",e,"auto"),t&&Object.keys(t).forEach((e=>{window.ga("set",e,t[e])})))}(t,i)}),[t,i]),(0,r.useEffect)((()=>{!function(){for(var e=arguments.length,t=new Array(e),i=0;ie.children?e.children.reduce(((e,t)=>e.concat(Array.isArray(t.children)?h(t):t)),[]):[],g=(e,t)=>h(e).find(t);var v=i(7338),b=i.n(v),f=i(3629),x=i(5962);const k=e=>{let{to:t="",url:i,...l}=e;i&&(t=i);const{isActive:s,...o}=l;return t.startsWith("http")||t.startsWith("//")?(0,d.jsx)("a",{href:t,target:"_blank",rel:"noopener noreferrer",...o}):(0,d.jsx)(n.rU,{to:t,...o})};k.propTypes={to:a().string,url:a().string};var y,w=k,j=i.p+"site-logo.c0e60df418e04f58.svg";function z(){return(0,d.jsx)("img",{className:"logo",src:j,alt:"webpack logo",width:122,height:35})}function E(e,t,i){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var l=i.call(e,"string");if("object"!=typeof l)return l;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}class C extends r.Component{constructor(){super(...arguments),E(this,"state",{active:!1})}componentDidMount(){document.addEventListener("keyup",this._closeDropdownOnEsc.bind(this),!0),document.addEventListener("focus",this._closeDropdownIfFocusLost.bind(this),!0),document.addEventListener("click",this._closeDropdownIfFocusLost.bind(this),!0)}_closeDropdownOnEsc(e){"Escape"===e.key&&this.state.active&&this.setState({active:!1},(()=>{this.dropdownButton.focus()}))}_closeDropdownIfFocusLost(e){this.state.active&&!this.dropdown.contains(e.target)&&this.setState({active:!1})}render(){let{className:e="",items:t=[]}=this.props,i=this.state.active?"dropdown__list--active":"";return(0,d.jsxs)("nav",{className:`dropdown ${e}`,ref:e=>this.dropdown=e,onMouseOver:this._toggle.bind(this,!0),onMouseLeave:this._toggle.bind(this,!1),children:[(0,d.jsxs)("button",{ref:e=>this.dropdownButton=e,"aria-haspopup":"true","aria-expanded":String(this.state.active),"aria-label":"Select language",onClick:this._handleClick.bind(this),children:[(0,d.jsxs)("svg",{viewBox:"0 0 610 560",xmlns:"http://www.w3.org/2000/svg",className:"dropdown__language text-gray-100 hover:text-blue-200 transition-colors duration-200",children:[(0,d.jsx)("path",{d:"m304.8 99.2-162.5-57.3v353.6l162.5-52.6z"}),(0,d.jsx)("path",{d:"m300.9 99 168.7-57.3v353.6l-168.7-52.5zm-200.7 358.4 200.7-66.9v-291.5l-200.7 66.9z",fill:"currentColor"}),(0,d.jsx)("path",{d:"m392.4 461.8 28.4 46.8 15-43.5zm-223.9-262.3c-1.1-1 1.4 8.6 4.8 12 6.1 6.1 10.8 6.9 13.3 7 5.6.2 12.5-1.4 16.5-3.1s10.9-5.2 13.5-10.4c.6-1.1 2.1-3 1.1-7.5-.7-3.5-3-4.8-5.7-4.6s-11 2.4-15 3.6-12.2 3.7-15.8 4.5-11.5-.3-12.7-1.5zm101.2 114.8c-1.6-.6-34.3-14.1-38.9-16.4a368 368 0 0 0 -17.5-7.5c12.3-19 20.1-33.4 21.2-35.6 1.9-4 15-29.5 15.3-31.1s.7-7.5.4-8.9-5.1 1.3-11.6 3.5-18.9 10.2-23.7 11.2-20.1 6.8-28 9.4c-7.8 2.6-22.7 7.1-28.8 8.8-6.1 1.6-11.4 1.8-14.9 2.8 0 0 .5 4.8 1.4 6.2s4.1 5 7.9 5.9c3.8 1 10 .6 12.8-.1s7.7-3.1 8.4-4.1c.7-1.1-.3-4.3.8-5.3s16.1-4.5 21.7-6.2 27.2-9.2 30.1-8.8a916 916 0 0 1 -23.9 47.7 821 821 0 0 1 -45 63.3c-5.3 6-18 21.5-22.4 25 1.1.3 9-.4 10.4-1.3 8.9-5.5 23.8-24.1 28.6-29.7a489.1 489.1 0 0 0 36.7-49.4c1.9.8 17.6 13.6 21.7 16.4a293 293 0 0 0 23.7 13.3c3.5 1.5 16.9 7.7 17.5 5.6.7-1.8-2.3-14.1-3.9-14.7z"}),(0,d.jsx)("path",{clipRule:"evenodd",d:"m194.1 484.7a204.9 204.9 0 0 0 30.7 14.5 233.6 233.6 0 0 0 46.4 12c.5 0 16 1.9 19.2 1.9h15.7c6.1-.5 11.8-.9 17.9-1.7 4.9-.7 10.3-1.6 15.5-2.8 3.8-.9 7.8-1.7 11.7-3 3.7-1 7.8-2.4 11.8-3.8l8.2-3.1c2.3-1 5.1-2.3 7.7-3.3a243 243 0 0 0 19.2-10c2.3-1.2 7.5-5.2 10.3-5.2 3.1 0 5.2 2.8 5.2 5.2 0 5.1-6.8 6.6-9.9 8.9-3.3 2.3-7.3 4-10.8 5.9-7 3.7-14.1 6.8-20.9 9.4a251 251 0 0 1 -27.3 8.5c-3.3.7-6.6 1.6-9.9 2.1-1.7.3-19.9 3.1-24.9 3.1h-23a293.9 293.9 0 0 1 -35.1-5.2 196 196 0 0 1 -33.1-10.3c-12-4.5-24.6-10.5-36.4-18.3-2.1-1.4-2.3-2.8-2.3-4.4a5 5 0 0 1 5.1-5.1c2.4.1 8 4.2 9 4.7zm101.4-98.1-189.9 63.2v-280.1l189.9-63.2zm10.6-288.3v292.7a6 6 0 0 1 -1.2 2.6c-.3.5-1 1.2-1.6 1.4a14621 14621 0 0 1 -203.1 67.6c-2.1 0-4-1.4-5.1-3.7 0-.2-.2-.3-.2-.7v-292.8c.3-.9.5-2.1 1.2-2.8 1.4-1.9 3.8-2.3 5.4-2.8 3-1 196.1-65.8 198.9-65.8 1.9 0 5.7 1.2 5.7 4.3z",fillRule:"evenodd"}),(0,d.jsx)("path",{clipRule:"evenodd",d:"m464.3 388-158-49.1v-236l158-53.7zm10.6-345.8v352.4c-.2 4-3 5.7-5.6 5.7-2.3 0-18.6-5.6-21.4-6.4l-65.8-20.4-14.6-4.7-12.9-4c-18.6-5.7-37.6-11.5-56.3-17.8-.7-.2-2.4-2.6-2.4-3.1v-246.1c.3-.9.7-1.9 1.6-2.6 1.4-1.6 61.1-21.4 84.7-29.3 6.3-2.3 84.8-29.3 87.3-29.3 3 .1 5.4 2.3 5.4 5.6z",fillRule:"evenodd"}),(0,d.jsx)("path",{d:"m515 461.8-211.1-67.3.9-292.8 210.2 66.9z"}),(0,d.jsx)("path",{clipRule:"evenodd",d:"m408.6 232.5-20.7 50.1 38.1 11.5zm-12.4-47.2 27.2 8.2 49.5 178.6-27.9-8.5-10-36.7-57.7-17.5-12.4 29.9-27.9-8.5z",fill:"currentColor",fillRule:"evenodd"})]}),(0,d.jsx)("i",{"aria-hidden":"true",className:"dropdown__arrow"})]}),(0,d.jsx)("div",{className:`dropdown__list ${i}`,children:(0,d.jsx)("ul",{children:t.map(((e,i)=>(0,d.jsx)("li",{children:(0,d.jsx)("a",{onKeyDown:this._handleArrowKeys.bind(this,i,t.length-1),ref:e=>this.links?this.links.push(e):this.links=[e],href:e.url,className:"px-5 block",children:(0,d.jsx)("span",{lang:e.lang,children:e.title})})},e.title)))})})]})}_handleArrowKeys(e,t,i){["ArrowDown","ArrowUp"].includes(i.key)&&i.preventDefault();let l=e;"ArrowDown"===i.key&&(l++,l>t&&(l=0)),"ArrowUp"===i.key&&(l--,l<0&&(l=t)),this.links[l].focus()}_handleClick(){this.setState({active:!this.state.active},(()=>{this.state.active&&this.links[0].focus()}))}_toggle(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.setState({active:e})}}function _(){return _=Object.assign?Object.assign.bind():function(e){for(var t=1;tr.createElement("svg",_({viewBox:"0 0 24 24"},e),y||(y=r.createElement("path",{d:"M12 2A10 10 0 0 0 2 12a10 10 0 0 0 6.8 9.5c.5 0 .7-.2.7-.5v-1.7C6.7 20 6.1 18 6.1 18c-.4-1.2-1-1.5-1-1.5-1-.6 0-.6 0-.6 1 0 1.5 1 1.5 1 .9 1.6 2.4 1.1 3 .9 0-.7.3-1.1.6-1.4-2.2-.2-4.6-1-4.6-4.9 0-1.1.4-2 1-2.7 0-.3-.4-1.3.2-2.7 0 0 .8-.2 2.7 1a9.4 9.4 0 0 1 5 0c2-1.2 2.8-1 2.8-1 .5 1.4.1 2.4 0 2.7.7.7 1 1.6 1 2.7 0 3.8-2.3 4.7-4.5 5 .4.2.7.8.7 1.8V21c0 .3.2.6.7.5 4-1.3 6.8-5 6.8-9.5A10 10 0 0 0 12 2z"})));function P(){return P=Object.assign?Object.assign.bind():function(e){for(var t=1;tr.createElement("svg",P({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 30 30"},e),S||(S=r.createElement("path",{d:"M28 6.937c-.957.425-1.985.711-3.064.84a5.343 5.343 0 0 0 2.345-2.951 10.696 10.696 0 0 1-3.388 1.295 5.334 5.334 0 0 0-9.089 4.864A15.143 15.143 0 0 1 3.809 5.411a5.321 5.321 0 0 0-.721 2.683 5.33 5.33 0 0 0 2.372 4.439 5.323 5.323 0 0 1-2.416-.667v.067a5.335 5.335 0 0 0 4.279 5.23 5.336 5.336 0 0 1-2.409.092 5.34 5.34 0 0 0 4.983 3.705 10.699 10.699 0 0 1-6.625 2.284c-.43 0-.855-.025-1.273-.075a15.102 15.102 0 0 0 8.177 2.396c9.812 0 15.176-8.128 15.176-15.177 0-.231-.005-.461-.015-.69A10.855 10.855 0 0 0 28 6.937z"})));function A(){return A=Object.assign?Object.assign.bind():function(e){for(var t=1;tr.createElement("svg",A({viewBox:"0 0 24 24"},e),M||(M=r.createElement("path",{d:"M17.4 20.2v-5.4h1.8V22H3v-7.2h1.8v5.4zM6.8 14.3l.3-1.7 8.8 1.8-.3 1.8zm1.1-4.2.8-1.6 8.1 3.8-.7 1.6zm2.3-4 1.1-1.4 7 5.8-1.2 1.4L10 6m4.7-4L20 9l-1.4 1-5.4-7 1.4-1m-8 16.5v-1.8h9v1.8z"})));function R(){return R=Object.assign?Object.assign.bind():function(e){for(var t=1;tr.createElement("svg",R({viewBox:"-62 138 25 25"},e),O||(O=r.createElement("path",{fill:"currentColor",d:"M-60.2 140.2h20.9c1 0 1.8.8 1.8 1.8s-.8 1.8-1.8 1.8h-20.9c-1 0-1.8-.8-1.8-1.8s.8-1.8 1.8-1.8zM-60.2 148.7h20.9c1 0 1.8.8 1.8 1.8s-.8 1.8-1.8 1.8h-20.9c-1 0-1.8-.8-1.8-1.8s.8-1.8 1.8-1.8zM-60.2 157.2h20.9c1 0 1.8.8 1.8 1.8s-.8 1.8-1.8 1.8h-20.9c-1 0-1.8-.8-1.8-1.8s.8-1.8 1.8-1.8z"})));const L={DARK:"dark",LIGHT:"light"},I="theme";var F=i(6509);const{DARK:H,LIGHT:W}=L;function U(){const[e,t]=(0,F.Z)(I,L.LIGHT);return(0,r.useEffect)((()=>{(e=>{document.documentElement.setAttribute("data-theme",e),e===L.DARK?document.documentElement.classList.add(L.DARK):document.documentElement.classList.remove(L.DARK)})(e)}),[e]),(0,d.jsx)("button",{"aria-label":e===H?"Switch to light theme":"Switch to dark theme",className:"bg-transparent border-none cursor-pointer text-[16px] p-0 inline-flex items-center text-gray-100 hover:text-blue-200 transition-colors duration-200",onClick:()=>(e=>{t(e)})(e===H?W:H),"data-testid":"hello-darkness",children:e===H?(0,d.jsx)("span",{className:"inline-flex items-center justify-center",children:(0,d.jsx)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,d.jsx)("path",{d:"M20.742 13.045a8.086 8.086 0 0 1-2.077.271c-2.135 0-4.14-.83-5.646-2.336a8.026 8.026 0 0 1-2.064-7.723A1 1 0 0 0 9.73 2.034a10.014 10.014 0 0 0-4.489 2.582c-3.898 3.898-3.898 10.243 0 14.143a9.936 9.936 0 0 0 7.072 2.93 9.93 9.93 0 0 0 7.07-2.929 10.007 10.007 0 0 0 2.583-4.491 1 1 0 0 0-1.224-1.224Zm-2.772 4.301a7.947 7.947 0 0 1-5.656 2.343 7.952 7.952 0 0 1-5.658-2.344c-3.118-3.119-3.118-8.195 0-11.314a7.923 7.923 0 0 1 2.06-1.483 10.027 10.027 0 0 0 2.89 7.848 9.973 9.973 0 0 0 7.848 2.891 8.037 8.037 0 0 1-1.484 2.059Z",fill:"currentColor"})})}):(0,d.jsx)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,d.jsx)("path",{d:"M12 18.14a.722.722 0 0 0-.722.722v2.166a.722.722 0 0 0 1.444 0v-2.166a.722.722 0 0 0-.722-.721ZM12 2.25a.722.722 0 0 0-.722.722v2.166a.722.722 0 0 0 1.444 0V2.972A.722.722 0 0 0 12 2.25ZM5.86 12a.722.722 0 0 0-.723-.722H2.972a.722.722 0 0 0 0 1.444h2.165A.722.722 0 0 0 5.86 12ZM21.028 11.278h-2.165a.722.722 0 0 0 0 1.444h2.165a.722.722 0 0 0 0-1.444ZM7.148 16.13a.72.72 0 0 0-.51.21l-1.533 1.534a.72.72 0 1 0 1.022 1.022l1.532-1.533a.724.724 0 0 0-.51-1.233ZM16.852 7.87a.72.72 0 0 0 .51-.21l1.533-1.533a.72.72 0 0 0 .211-.511.72.72 0 0 0-.722-.722.72.72 0 0 0-.51.21L16.34 6.639a.72.72 0 0 0-.211.51.72.72 0 0 0 .722.722ZM6.127 5.105a.72.72 0 0 0-.511-.211.72.72 0 0 0-.722.722.72.72 0 0 0 .21.51L6.638 7.66a.72.72 0 0 0 .511.211.72.72 0 0 0 .722-.722.72.72 0 0 0-.21-.51L6.126 5.105ZM17.363 16.34a.72.72 0 1 0-1.022 1.022l1.532 1.533a.72.72 0 0 0 1.022 0 .72.72 0 0 0 0-1.021l-1.532-1.533ZM12 7.5c-2.48 0-4.5 2.02-4.5 4.5s2.02 4.5 4.5 4.5 4.5-2.02 4.5-4.5-2.02-4.5-4.5-4.5Z",fill:"currentColor"})})})}function q(e){let{children:t,url:i,isactive:l}=e,s={};l&&(s={isactive:l});const o="text-gray-100 dark:text-gray-100 text-sm font-light uppercase hover:text-blue-200";return i.startsWith("http")||i.startsWith("//")?(0,d.jsx)("a",{href:i,target:"_blank",rel:"noopener noreferrer",className:o,children:t}):(0,d.jsx)(n.OL,{...s,className:e=>{let{isActive:t}=e;return t?`${o} !text-blue-200`:o},to:i,children:t})}function G(e){let{children:t,to:i,title:l}=e;return(0,d.jsx)(w,{to:i,className:"inline-flex items-center text-gray-100 dark:text-gray-200 hover:text-blue-200",title:`webpack on ${l}`,children:t})}U.propTypes={theme:a().oneOf([H,W]),switchTheme:a().func},U.defaultProps={theme:W},q.propTypes={children:a().node.isRequired,url:a().string.isRequired,isactive:a().func},G.propTypes={children:a().node.isRequired,to:a().string.isRequired,title:a().string.isRequired};const $={"aria-hidden":!0,fill:"currentColor",width:16};function J(e){let{links:t,pathname:i,hash:l="",toggleSidebar:o}=e;const[a,c]=(0,r.useState)(l),p=(0,s.TH)();return(0,r.useEffect)((()=>{c(l)}),[l]),(0,d.jsx)(d.Fragment,{children:(0,d.jsxs)("header",{className:"bg-blue-800 dark:bg-gray-900",children:[(0,d.jsxs)("div",{className:"flex items-center py-10 px-[16px] justify-between md:px-[24px] md:max-w-[1024px] md:mx-auto md:justify-start",children:[(0,d.jsx)("button",{className:"bg-transparent border-none md:hidden",onClick:o,children:(0,d.jsx)(B,{width:20,height:20,className:"fill-current text-white"})}),(0,d.jsx)(w,{to:"/",className:"md:mr-auto",children:(0,d.jsx)(z,{})}),(0,d.jsxs)("nav",{className:"hidden md:inline-grid md:grid-flow-col md:gap-x-[18px]",children:[t.map((e=>{let{content:t,url:i,isActive:l}=e;return(0,d.jsx)(q,{url:i,isActive:l,children:t},i)})),[{to:"https://github.com/webpack/webpack",title:"GitHub",children:(0,d.jsx)(N,{...$})},{to:"https://twitter.com/webpack",title:"Twitter",children:(0,d.jsx)(D,{...$})},{to:"https://stackoverflow.com/questions/tagged/webpack",title:"StackOverflow",children:(0,d.jsx)(T,{...$})}].map((e=>{let{to:t,title:i,children:l}=e;return(0,d.jsx)(G,{to:t,title:i,children:l},t)})),(0,d.jsx)(C,{className:"",items:[{title:"English",url:`https://webpack.js.org${i}${a}`},{lang:"zh",title:"中文",url:`https://webpack.docschina.org${i}${a}`},{lang:"ko",title:"한국어",url:`https://webpack.kr${i}${a}`}]})]}),(0,d.jsxs)("div",{className:"inline-flex items-center ml-[18px]",children:[(0,d.jsx)(U,{}),(0,d.jsx)(x.F,{apiKey:"fac401d1a5f68bc41f01fb6261661490",indexName:"webpack-js-org",disableUserPersonalization:!0,placeholder:"Search webpack documentation",transformItems:e=>e.map((e=>{let{url:t,...i}=e;const{origin:l}=new URL(t);return{...i,url:t.replace(new RegExp(`^${l}`),"")}})),hitComponent:e=>{let{hit:t,children:i}=e;return(0,d.jsx)(n.rU,{to:t.url,children:i})}})]})]}),t.filter((e=>e.children)).map((e=>e.isactive&&!e.isactive({},p)?null:(0,d.jsx)("div",{className:"bg-gray-100 dark:bg-gray-800 hidden md:block",children:(0,d.jsx)("div",{className:"md:max-w-[1024px] md:mx-auto md:grid md:grid-flow-col md:justify-end md:gap-x-[20px] md:px-[24px]","data-testid":"sub-navigation",children:e.children.map((e=>{const t="text-blue-400 py-5 text-sm capitalize hover:text-black dark:hover:text-white",i=p.pathname.startsWith(e.url);return(0,d.jsx)(n.OL,{to:e.url,title:e.title,className:()=>i?`!text-black dark:!text-white ${t}`:t,children:"api"===e.content?e.content.toUpperCase():e.content},e.url)}))})},e.url)))]})})}J.propTypes={pathname:a().string,hash:a().string,links:a().array,toggleSidebar:a().func,theme:a().string,switchTheme:a().func};var V=J,K=i(151);function X(e,t,i){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var l=i.call(e,"string");if("object"!=typeof l)return l;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}class Z extends r.Component{constructor(){super(...arguments),X(this,"_container",null),X(this,"_initialTouchPosition",{}),X(this,"_lastTouchPosition",{}),X(this,"_toggleBodyListener",(e=>{let t=e?"addEventListener":"removeEventListener";window[t]("touchstart",this._handleBodyClick),window[t]("mousedown",this._handleBodyClick)})),X(this,"_handleBodyClick",(e=>{const{isOpen:t,toggle:i}=this.props;t&&!this._container.contains(e.target)&&i(!1)})),X(this,"_handleTouchStart",(e=>{this._initialTouchPosition.x=e.touches[0].pageX,this._initialTouchPosition.y=e.touches[0].pageY,this._container.classList.add("no-delay")})),X(this,"_handleTouchMove",(e=>{let t=this._initialTouchPosition.x-e.touches[0].pageX,i=this._initialTouchPosition.y-e.touches[0].pageY,l=Math.abs(i/t);t>0&&l<.8&&(e.preventDefault(),this._container.style.transform=`translateX(-${t}px)`,this._lastTouchPosition.x=e.touches[0].pageX,this._lastTouchPosition.y=e.touches[0].pageY)})),X(this,"_handleOpenerTouchMove",(e=>{let t=e.touches[0].pageX-this._initialTouchPosition.x,i=this._initialTouchPosition.y-e.touches[0].pageY,l=Math.abs(i/t);t>0&&t<295&&l<.8&&(e.preventDefault(),this._container.style.transform=`translateX(calc(-100% + ${t}px))`,this._lastTouchPosition.x=e.touches[0].pageX,this._lastTouchPosition.y=e.touches[0].pageY)})),X(this,"_handleTouchEnd",(e=>{const{isOpen:t}=this.props;this._container.classList.remove("no-delay"),this._container.style.transform="",t&&this._initialTouchPosition.x-this._lastTouchPosition.x>20?this.props.toggle(!1):!t&&this._lastTouchPosition.x-this._initialTouchPosition.x>20&&(this.props.toggle(!0),e.preventDefault(),e.stopPropagation())}))}render(){let{isOpen:e,toggle:t}=this.props,i=e?" sidebar-mobile--visible":"";return this._toggleBodyListener(e),(0,d.jsxs)("nav",{className:`sidebar-mobile${i}`,ref:e=>this._container=e,onTouchStart:this._handleTouchStart,onTouchMove:this._handleTouchMove,onTouchEnd:this._handleTouchEnd,children:[(0,d.jsx)("div",{className:"sidebar-mobile__toggle",onTouchStart:this._handleTouchStart,onTouchMove:this._handleOpenerTouchMove,onTouchEnd:this._handleTouchEnd}),(0,d.jsxs)("div",{className:"sidebar-mobile__content",children:[(0,d.jsx)("span",{role:"button",className:"sidebar-mobile__close",onClick:t.bind(null,!1),children:(0,d.jsx)(K.Z,{fill:"#fff",width:20})}),this._getSections()]})]})}_getSections(){let e="";return window&&void 0!==window.location&&(e=window.location.pathname),this.props.sections.map((t=>{let i="/"!==t.url&&e.startsWith(t.url);return(0,d.jsxs)("div",{className:"sidebar-mobile__section "+(i?"sidebar-mobile__section--active":""),children:[(0,d.jsx)(w,{className:"sidebar-mobile__section-header",to:t.url,onClick:this.props.toggle.bind(null,!1),children:(0,d.jsx)("h3",{children:t.title||t.url})},t.url),this._getPages(t.children)]},t.url)}))}_getPages(e){let t="";return void 0!==window.location&&(t=window.location.pathname),e.map((e=>{let i=`${e.url}`,l=t===i;return(0,d.jsx)(w,{className:"sidebar-mobile__page sidebar-mobile__section-child "+(l?"sidebar-mobile__page--active":""),to:i,onClick:this.props.toggle.bind(null,!1),children:e.title},i)}))}}function Y(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{className:t=""}=e;return(0,d.jsx)("div",{className:`container ${t}`,children:e.children})}X(Z,"propTypes",{isOpen:a().bool,toggle:a().func,sections:a().array}),Y.propTypes={className:a().string,children:a().node};var Q=i(193),ee=i.n(Q);function te(e,t,i){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var l=i.call(e,"string");if("object"!=typeof l)return l;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}class ie extends r.Component{constructor(){super(...arguments),te(this,"state",{x:0,y:0,z:0,iteration:0}),te(this,"_spin",(()=>{let e={},t=this._getRandomAxis(),i=Math.random()<.5?-1:1;e[t]=90*i,this.setState(e)})),te(this,"_reset",(()=>{this.setState({x:0,y:0,z:0})}))}render(){let{x:e,y:t,z:i}=this.state,{theme:l,depth:n,className:s=""}=this.props;return(0,d.jsx)("div",{className:`cube__container ${s}`,style:{width:1.5*n+"px",height:1.5*n+"px",paddingLeft:n/1.7+"px"},children:(0,d.jsxs)("span",{ref:e=>this.container=e,className:`cube cube--${l}`,style:{width:`${n}px`,paddingBottom:.5*n+"px"},children:[(0,d.jsx)("figure",{className:"cube__outer",style:{width:`${n}px`,height:`${n}px`,transform:`translateX(-50%)\n scale3d(1,1,1)\n rotateX(${e}deg)\n rotateY(${t}deg)\n rotateZ(${i}deg)`},children:this._getFaces("outer")}),(0,d.jsx)("figure",{className:"cube__inner",style:{width:`${n}px`,height:`${n}px`,transform:`translateX(-50%)\n scale3d(0.5,0.5,0.5)\n rotateX(${-e}deg)\n rotateY(${-t}deg)\n rotateZ(${-i}deg)`},children:this._getFaces("inner")})]})})}componentDidMount(){let{hover:e,continuous:t,repeatDelay:i}=this.props;if(e)this.container.addEventListener("mouseenter",this._spin),this.container.addEventListener("mouseleave",this._reset);else if(t){let e=0,t="y",l=()=>{let i={};i[t]=e+=90,this.setState({...i,iteration:(this.state.iteration+1)%4}),n()},n=()=>setTimeout((()=>requestAnimationFrame(l)),i);this._timeout=n()}}componentWillUnmount(){let{hover:e,continuous:t}=this.props;e?(this.container.removeEventListener("mouseenter",this._spin),this.container.removeEventListener("mouseleave",this._reset)):t&&clearTimeout(this._timeout)}_getFaces(e){let{iteration:t}=this.state;const i={0:{left:[1,1,1,6],right:[6,1,1,1],top:[1,1,1,1],bottom:[6,1,1,6]},1:{left:[1,1,1,1],right:[1,1,1,1],top:[1,1,1,1],bottom:[1,1,1,1]},2:{left:[1,1,6,6],right:[6,6,1,1],top:[6,1,1,6],bottom:[1,6,6,1]},3:{left:[6,1,1,1],right:[1,6,1,1],top:[1,1,1,1],bottom:[6,6,1,1]},4:{left:[1,1,6,1],right:[1,1,1,6],top:[1,1,1,1],bottom:[1,1,6,6]},5:{left:[1,6,1,1],right:[1,1,6,1],top:[1,1,1,1],bottom:[1,6,6,1]}};return["rotateX(0deg)","rotateX(-90deg)","rotateX(90deg)","rotateY(-90deg)","rotateY(90deg)","rotateY(180deg)"].map(((l,n)=>{const s="outer"===e?{borderTopWidth:i[n].top[t],borderRightWidth:i[n].right[t],borderBottomWidth:i[n].bottom[t],borderLeftWidth:i[n].left[t]}:{};return(0,d.jsx)("section",{className:"cube__face",style:{transform:`${l} translateZ(${this.props.depth/2}px)`,...s}},n)}))}_getRandomAxis(){let e=Object.keys(this.state);return e[Math.floor(Math.random()*e.length)]}}function le(e,t,i){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var l=i.call(e,"string");if("object"!=typeof l)return l;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}te(ie,"propTypes",{hover:a().bool,theme:a().string,depth:a().number,repeatDelay:a().number,className:a().string,continuous:a().bool}),te(ie,"defaultProps",{hover:!1,theme:"dark",depth:30,repeatDelay:1e3});class ne extends r.PureComponent{constructor(){super(...arguments),le(this,"state",{currentIndex:0,contentHeight:0}),le(this,"_calculateContentHeight",(()=>{this.setState({contentHeight:this.content.clientHeight})})),le(this,"_handleTransitionEnd",(()=>{const{children:e,repeatDelay:t}=this.props;this.textRotatorWrap&&(this.textRotatorWrap.classList.remove("text-rotater--slide-up"),this.setState({currentIndex:(this.state.currentIndex+1)%r.Children.count(e)},(()=>{setTimeout((()=>{this.textRotatorWrap&&this.textRotatorWrap.classList.add("text-rotater--slide-up")}),t)})))}))}render(){const{children:e,maxWidth:t}=this.props,{currentIndex:i,contentHeight:l}=this.state,n=r.Children.count(e),s=(0,r.cloneElement)(e[i],{ref:e=>this.content=e}),o=(0,r.cloneElement)(e[(i+1)%n]);return(0,d.jsx)("div",{className:"text-rotater",children:(0,d.jsxs)("div",{className:"text-rotater__wrap",ref:e=>this.textRotatorWrap=e,onTransitionEnd:this._handleTransitionEnd,style:{height:l,width:t},children:[s,o]})})}componentDidMount(){const{delay:e}=this.props;setTimeout((()=>{this._calculateContentHeight()}),50),setTimeout((()=>{this.textRotatorWrap&&this.textRotatorWrap.classList.add("text-rotater--slide-up")}),e),window.addEventListener("resize",this._calculateContentHeight)}componentWillUnmount(){window.removeEventListener("resize",this._calculateContentHeight)}}le(ne,"defaultProps",{delay:0,repeatDelay:3e3}),le(ne,"propTypes",{children:a().arrayOf(a().node),delay:a().number,repeatDelay:a().number,maxWidth:a().number});class se extends r.Component{render(){return(0,d.jsxs)("section",{className:"splash-viz dark:bg-gray-900",children:[(0,d.jsxs)("h1",{className:"splash-viz__heading",children:[(0,d.jsx)("span",{children:" bundle your"}),(0,d.jsxs)(ne,{delay:5e3,repeatDelay:5e3,maxWidth:110,children:[(0,d.jsx)("span",{children:" assets "}),(0,d.jsx)("span",{children:" scripts "}),(0,d.jsx)("span",{children:" images "}),(0,d.jsx)("span",{children:" styles "})]})]}),(0,d.jsx)("div",{className:"splash-viz__modules",dangerouslySetInnerHTML:{__html:ee().body}}),(0,d.jsx)(ie,{className:"splash-viz__cube",depth:120,repeatDelay:5e3,continuous:!0})]})}}const oe=e=>(0,d.jsx)("div",{className:"markdown",children:e.children});oe.propTypes={children:a().node};var ae=oe;const re=()=>'\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n';function de(){return(0,d.jsxs)("div",{className:"placeholder",children:[(0,d.jsx)("p",{children:" "}),(0,d.jsx)("p",{children:" "}),(0,d.jsx)("p",{children:" "})]})}var ce=i(1975);const pe=(0,r.lazy)((()=>i.e(1360).then(i.bind(i,9759)))),ue=()=>(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)("h2",{children:"Latest Sponsors"}),(0,d.jsx)(de,{}),(0,d.jsx)("h2",{children:"Platinum Sponsors"}),(0,d.jsx)(de,{}),(0,d.jsx)("h2",{children:"Gold Sponsors"}),(0,d.jsx)(de,{}),(0,d.jsx)("h2",{children:"Silver Sponsors"}),(0,d.jsx)(de,{}),(0,d.jsx)("h2",{children:"Bronze Sponsors"}),(0,d.jsx)(de,{}),(0,d.jsx)("h2",{children:"Backers"}),(0,d.jsx)(de,{})]});var me,he=()=>{const[e,t]=(0,r.useState)(!1),[i,l]=(0,r.useState)((()=>Math.random()<.33?"monthly":"total"));return(0,r.useEffect)((()=>{b()&&t(!0)}),[]),(0,d.jsxs)("div",{className:"splash",children:[(0,d.jsx)(se,{}),(0,d.jsx)("div",{className:"splash__section splash__section--dark page__content",children:(0,d.jsx)(Y,{children:(0,d.jsx)(ae,{children:(0,d.jsx)(ce.default,{})})})}),(0,d.jsx)("div",{className:"splash__section page__content",children:(0,d.jsx)(Y,{children:(0,d.jsxs)(ae,{children:[(0,d.jsx)("h1",{id:"sponsors",children:"Support the Team"}),(0,d.jsx)("p",{children:"Through contributions, donations, and sponsorship, you allow webpack to thrive. Your donations directly support office hours, continued enhancements, and most importantly, great documentation and learning material!"}),e?(0,d.jsxs)(r.Suspense,{fallback:(0,d.jsx)(ue,{}),children:[(0,d.jsx)("p",{children:(0,d.jsxs)("label",{htmlFor:"support-type",children:[(0,d.jsx)("input",{id:"support-type",type:"checkbox",checked:"monthly"===i,onChange:e=>l(e.target.checked?"monthly":"total")}),"Show sponsors by their average monthly amount of sponsoring in the last year."]})}),(0,d.jsx)(pe,{type:i,rank:"latest"}),(0,d.jsx)(pe,{type:i,rank:"platinum"}),(0,d.jsx)(pe,{type:i,rank:"gold"}),(0,d.jsx)(pe,{type:i,rank:"silver"}),(0,d.jsx)(pe,{type:i,rank:"bronze"}),(0,d.jsx)(pe,{type:i,rank:"backer"})]}):(0,d.jsx)(ue,{})]})})})]})},ge=i.p+"ag-grid-logo.27db91190cf56daf.png",ve=i.p+"icon-square-small.9e8aff7a67a5dd20.svg",be=()=>(0,d.jsx)("div",{className:"sponsors",children:(0,d.jsxs)(w,{className:"sponsors__content",to:"https://www.ag-grid.com/?utm_source=webpack&utm_medium=banner&utm_campaign=sponsorship",children:[(0,d.jsx)("img",{src:ge,width:260,height:140,alt:"ag grid",loading:"lazy"}),(0,d.jsx)("img",{className:"sponsors__img__webpack",src:ve,alt:"webpack",width:150,height:150,loading:"lazy"}),(0,d.jsx)("div",{className:"sponsors__content-cont",children:"ag-grid is proud to partner with webpack"})]})}),fe=i(3530),xe=i.n(fe);function ke(){return ke=Object.assign?Object.assign.bind():function(e){for(var t=1;tr.createElement("svg",ke({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"},e),me||(me=r.createElement("path",{d:"m9.2 4.5 4.5 4.7c.2.2.3.5.3.8s-.1.6-.3.8l-4.5 4.7c-.5.4-1.2.4-1.7 0-.4-.5-.4-1 0-1.6l3.8-3.9-3.8-4c-.4-.4-.4-1 0-1.5.5-.4 1.2-.4 1.7 0z"})));function je(){return je=Object.assign?Object.assign.bind():function(e){for(var t=1;tr.createElement("svg",je({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"},e),ye||(ye=r.createElement("path",{d:"M10 3.3c-.6 0-1 .4-1.1 1.1v11.2c0 .3.2.6.4.8s.5.4.8.4c.6 0 1-.4 1.1-1.1V4.5c0-.3-.2-.6-.4-.8s-.5-.4-.8-.4z"})));function Ee(e,t,i){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var l=i.call(e,"string");if("object"!=typeof l)return l;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}const Ce="sidebar-item";class _e extends r.Component{constructor(){super(...arguments),Ee(this,"state",{open:this._isOpen(this.props)})}scrollTop(e){""===window.location.hash&&(e.metaKey||e.ctrlKey||window.scrollTo(0,0))}renderAnchors(e){return(0,d.jsx)("ul",{className:`${Ce}__anchors`,children:e.map((e=>(0,d.jsxs)("li",{className:`${Ce}__anchor`,title:e.title,children:[(0,d.jsx)(n.OL,{to:this._generateAnchorURL(e),children:e.title2}),e.children&&this.renderAnchors(e.children)]},this._generateAnchorURL(e))))})}render(){let{title:e,anchors:t=[]}=this.props,i=this.state.open?`${Ce}--open`:"",l=0===t.length?`${Ce}--disabled`:"";const s=t.filter((e=>e.level>1)),o=xe()(e,s);return(0,d.jsxs)("div",{className:`${Ce} ${i} ${l}`,children:[t.length>0?(0,d.jsx)(we,{width:15,height:17,fill:"#175d96",className:`${Ce}__toggle`,onClick:this._toggle.bind(this)}):(0,d.jsx)(ze,{className:`${Ce}__toggle`,width:15,height:17,fill:"#175d96"}),(0,d.jsx)(n.OL,{end:!0,className:`${Ce}__title`,to:this.props.url,onClick:this.scrollTop,children:e},this.props.url),t.length>0?this.renderAnchors(o):null]})}UNSAFE_componentWillReceiveProps(e){e.currentPage!==this.props.currentPage&&this.setState({open:this._isOpen(e)})}_isOpen(e){return RegExp(`${e.currentPage}/?$`).test(e.url)}_toggle(){this.setState({open:!this.state.open})}_generateAnchorURL(e){let{url:t}=this.props;return e.id?`${t}#${e.id}`:t}}Ee(_e,"propTypes",{title:a().string,anchors:a().array,url:a().string,currentPage:a().string});var Se=i.p+"icon-print.3c147a8b5a684f88.svg";const Ne=["api","concepts","configuration","contribute","guides","loaders","migrate","plugins"];function Pe(e){const{url:t}=e,i=function(e){let t=e.split("/");return!!Ne.includes(t[1])&&`/${t[1]}/printable/`}(t);return i?(0,d.jsxs)("div",{className:"sidebar-item sidebar-item--disabled`",children:[(0,d.jsx)(ze,{className:"sidebar-item__toggle",width:15,height:17,fill:"#175d96"}),(0,d.jsxs)("a",{className:"sidebar-item__title sidebar-link__print",href:i,rel:"nofollow noopener noreferrer",alt:"Print",title:"Print",target:"_blank",children:["Print Section",(0,d.jsx)("img",{src:Se,width:27,height:20,alt:"Printer Icon"})]})]}):null}var Me;function De(){return De=Object.assign?Object.assign.bind():function(e){for(var t=1;tr.createElement("svg",De({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"},e),Me||(Me=r.createElement("path",{d:"M4.5 7.5c.5-.4 1-.4 1.6 0l3.9 3.8 4-3.8c.4-.4 1-.4 1.5 0 .4.5.4 1.2 0 1.7l-4.7 4.5a1 1 0 0 1-1.6 0L4.5 9.2c-.4-.5-.4-1.2 0-1.7z"})));function Te(){return Te=Object.assign?Object.assign.bind():function(e){for(var t=1;tr.createElement("svg",Te({xmlns:"http://www.w3.org/2000/svg",xmlSpace:"preserve",width:40,height:40,viewBox:"0 0 50 50"},e),Ae||(Ae=r.createElement("path",{d:"M43.935 25.145c0-10.318-8.364-18.683-18.683-18.683-10.318 0-18.683 8.365-18.683 18.683h4.068c0-8.071 6.543-14.615 14.615-14.615s14.615 6.543 14.615 14.615h4.068z"},r.createElement("animateTransform",{attributeName:"transform",attributeType:"xml",dur:"0.6s",from:"0 25 25",repeatCount:"indefinite",to:"360 25 25",type:"rotate"}))));const Be=[5,4],Le=5;function Ie(e){let{className:t="",pages:i,currentPage:l}=e;const[n,s]=(0,r.useState)(Le),[o,a]=(0,r.useState)(!1);let c;return(0,r.useEffect)((()=>{if(n===Le)return;const e=window.location.href,t=new URL(e);t.hostname=`v${n}.webpack.js.org`,window.location.href=t.href}),[n]),(0,d.jsx)("nav",{className:`sidebar ${t}`,children:(0,d.jsxs)("div",{className:"sidebar__inner",children:[(0,d.jsxs)("div",{className:"relative z-0 bg-white dark:bg-gray-100 ",children:[(0,d.jsx)("select",{className:"text-gray-600 text-14 px-5 py-5 appearance-none box-border border border-gray-200 border-solid flex-col flex w-full rounded-none bg-transparent bg-none",value:n,onChange:e=>{s(+e.target.value),+e.target.value!==Le&&a(!0)},children:Be.map((e=>(0,d.jsxs)("option",{value:e,children:["webpack ",e]},e)))}),o?(0,d.jsx)(Re,{className:"absolute right-5 top-5 fill-current text-gray-300 z-[-1]",width:20,height:20}):(0,d.jsx)(Oe,{className:"absolute right-5 top-5 fill-current text-gray-300 z-[-1]",width:20,height:20})]}),(0,d.jsx)(Pe,{url:l}),i.map(((e,t)=>{let i=c!==e.group&&"-"!==e.group;return c=e.group,(0,d.jsxs)("div",{children:[i?(0,d.jsx)("h4",{className:"sidebar__group",children:c}):null,(0,d.jsx)(_e,{index:t,url:e.url,title:e.title,anchors:e.anchors,currentPage:l})]},e.url)}))]})})}Ie.propTypes={className:a().string,pages:a().array,currentPage:a().string};var Fe=i.p+"cc.185f5779f354f6e9.svg",He=i.p+"by.d2da85793ea9d7bd.svg",We=()=>(0,d.jsx)("footer",{className:"footer",children:(0,d.jsxs)(Y,{className:"footer__inner",children:[(0,d.jsxs)("section",{className:"footer__left",children:[(0,d.jsx)(w,{className:"footer__link",to:"/guides/getting-started/",children:"Get Started"}),(0,d.jsx)(w,{className:"footer__link",to:"/comparison/",children:"Comparison"}),(0,d.jsx)(w,{className:"footer__link",to:"https://privacy-policy.openjsf.org/",children:"Privacy Policy"})]}),(0,d.jsx)("section",{className:"footer__middle",children:(0,d.jsx)(w,{to:"/",className:"footer__icon",children:(0,d.jsx)("img",{src:ve,alt:"webpack icon",width:35,height:35})})}),(0,d.jsxs)("section",{className:"footer__right",children:[(0,d.jsx)(w,{className:"footer__link",to:"https://webpack.threadless.com/",children:"Swag Store"}),(0,d.jsx)(w,{className:"footer__link",to:"/awesome-webpack/",children:"Awesome webpack"}),(0,d.jsx)(w,{className:"footer__link",to:"/glossary/",children:"Glossary"}),(0,d.jsx)(w,{className:"footer__link",to:"/branding/",children:"Branding"}),(0,d.jsx)(w,{className:"footer__link",to:"https://gitter.im/webpack/webpack",children:"Gitter"}),(0,d.jsx)(w,{className:"footer__link",to:"https://github.com/webpack/webpack/releases",children:"Changelog"}),(0,d.jsxs)(w,{className:"footer__link footer__license",to:"/license",children:[(0,d.jsx)("img",{alt:"Creative Commons License",src:Fe,width:25,height:25}),(0,d.jsx)("img",{alt:"Creative Commons License",src:He,width:25,height:25})]})]})]})}),Ue=i(4760);const qe="https://github.com/webpack/webpack.js.org/edit/main/";function Ge(){return(0,d.jsx)("span",{className:"mx-5 text-black font-bold dark:text-white",children:"·"})}Je.propTypes={page:a().shape({repo:a().string})};const $e="text-gray-500 dark:text-gray-500 text-sm cursor-pointer font-sans hover:underline";function Je(e){let{page:t={}}=e;const i=t.edit||Ue.resolve(qe,t.path);return(0,d.jsxs)("div",{className:"print:hidden mt-20",children:[(0,d.jsx)("a",{className:$e,href:i,children:"Edit this page"}),(0,d.jsx)(Ge,{}),(0,d.jsx)("a",{className:$e,onClick:Ve,children:"Print this page"}),t.repo?(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(Ge,{}),(0,d.jsx)("a",{className:$e,href:t.repo,children:"Jump to repository"})]}):null]})}function Ve(e){e.preventDefault(),window.print()}var Ke=i(412),Xe=i.n(Ke),Ze=i(2807);const Ye=["bartushek","rynclark","henriquea","makuzaverite","MijaelWatts","Kolhar730","grrizzly","maxloh","varunjayaraman"];function Qe(e){let{contributor:t,inView:i}=e;return(0,d.jsx)("a",{href:`https://github.com/${t}`,children:(0,d.jsx)("img",{width:45,height:45,alt:t,title:t,className:"w-full rounded-full shadow",src:i?`https://github.com/${t}.png?size=90`:Ze})},t)}function et(e){let{contributors:t}=e;const[i,l]=(0,r.useState)(!1);return t.length?(0,d.jsx)(Xe(),{delayedCall:!0,partialVisibility:!0,intervalDelay:300,onChange:e=>{e&&l(e)},children:(0,d.jsx)("div",{children:(0,d.jsx)("div",{className:"grid gap-[10px] lg:gap-[15px] grid-cols-contributors",children:t.filter((e=>!1===Ye.includes(e))).map((e=>(0,d.jsx)(Qe,{contributor:e,inView:i},e)))})})}):(0,d.jsx)("noscript",{})}function tt(e){let{previous:t,next:i}=e;return t||i?(0,d.jsxs)("div",{className:"adjacent-links print:hidden",children:[t&&(0,d.jsxs)("div",{className:"adjacent-links__prev",children:[(0,d.jsx)("div",{children:"« Previous"}),(0,d.jsx)(w,{className:"adjacent-links__link",to:t.url,children:t.title})]}),i&&(0,d.jsxs)("div",{className:"adjacent-links__next",children:[(0,d.jsx)("div",{className:"adjacent-links__label--next",children:"Next »"}),(0,d.jsx)(w,{className:"adjacent-links__link",to:i.url,children:i.title})]})]}):null}function it(e){const{title:t,contributors:i=[],related:l=[],previous:n,next:o,...a}=e,c=e.content instanceof Promise,[p,u]=(0,r.useState)(c?re():()=>e.content.default||e.content),[m,h]=(0,r.useState)(!c);(0,r.useEffect)((()=>{e.content instanceof Promise&&e.content.then((e=>{u((()=>e.default||e)),h(!0)})).catch((()=>u("Error loading content.")))}),[e.content]);const{hash:g,pathname:v}=(0,s.TH)();(0,r.useEffect)((()=>{let e;if(m)if(g){const t=document.querySelector("#md-content");document.querySelector(g)?document.querySelector(g).scrollIntoView():(e=new MutationObserver((()=>{const e=document.querySelector(g);e&&e.scrollIntoView()})),e.observe(t,{childList:!0,attributes:!1,subtree:!1}))}else window.scrollTo(0,0);return()=>{e&&e.disconnect()}}),[m,v,g]);const b=i.length,f=m&&l&&0!==l.length,x=m&&i&&0!==b;let k;return k="function"==typeof p?p({}).props.children:(0,d.jsx)("div",{dangerouslySetInnerHTML:{__html:p}}),(0,d.jsx)("section",{className:"page",children:(0,d.jsxs)(ae,{children:[(0,d.jsx)("h1",{children:t}),a.thirdParty?(0,d.jsxs)("div",{className:"italic my-[20px]",children:[(0,d.jsx)("strong",{className:"font-bold",children:"Disclaimer:"})," ",t," is a third-party package maintained by community members, it potentially does not have the same support, security policy or license as webpack, and it is not maintained by webpack."]}):null,(0,d.jsx)("div",{id:"md-content",children:k}),f&&(0,d.jsxs)("div",{className:"print:hidden",children:[(0,d.jsx)("h2",{children:"Further Reading"}),(0,d.jsx)("ul",{children:l.map(((e,t)=>(0,d.jsx)("li",{children:(0,d.jsx)(w,{to:e.url,children:e.title})},t)))})]}),(0,d.jsx)(Je,{page:a}),(n||o)&&(0,d.jsx)(tt,{previous:n,next:o}),x&&(0,d.jsxs)("div",{"data-testid":"contributors",className:"print:hidden",children:[(0,d.jsxs)("h2",{className:"!font-sans !font-normal",children:[b," ",1===b?"Contributor":"Contributors"]}),(0,d.jsx)(et,{contributors:i})]})]})})}function lt(){return(0,d.jsxs)("div",{className:"page markdown",children:[(0,d.jsx)("h1",{children:"Page Not Found"}),(0,d.jsx)("p",{children:"Oops! The page you are looking for has been removed or relocated."}),(0,d.jsx)(n.rU,{className:"button",to:"/",children:"Go to Homepage"})]})}function nt(e){return(0,d.jsx)("span",{className:"badge",children:e.text})}et.propTypes={contributors:a().array.isRequired},Qe.propTypes={contributor:a().string.isRequired,inView:a().bool.isRequired},tt.propTypes={previous:a().shape({url:a().string,title:a().string}),next:a().shape({url:a().string,title:a().string})},it.propTypes={title:a().string,contributors:a().array,related:a().array,previous:a().object,next:a().object,content:a().oneOfType([a().shape({then:a().func.isRequired,default:a().string})])},nt.propTypes={text:a().string.isRequired};var st=i.p+"open-in-stackblitz-button.d5768454f28617a0.svg";function ot(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const{example:t="",description:i="Check out this guide live on StackBlitz."}=e,l=`https://stackblitz.com/github/webpack/webpack.js.org/tree/main/examples/${t}`;return(0,d.jsxs)("aside",{className:"preview",children:[(0,d.jsx)("h6",{className:"preview__prefix",children:"live preview"}),(0,d.jsx)("p",{children:i}),(0,d.jsx)("a",{href:l,target:"_blank",rel:"noopener noreferrer",children:(0,d.jsx)("img",{src:st,alt:"Open in StackBlitz"})})]})}function at(e){return e.href.startsWith("/")?(0,d.jsx)(n.rU,{...e,to:e.href}):(0,d.jsx)("a",{...e})}ot.propTypes={description:a().string,example:a().string},at.propTypes={href:a().string.isRequired};var rt=i(2883),dt=i.p+"favicon.a3dd58d3142f7566.ico",ct=i.p+"logo-on-white-bg.4a16a9aed80e42ee.svg",pt=i.p+"icon-pwa-512x512.934507c816afbcdb.png",ut=JSON.parse('{"path":"./src/content","name":"content","children":[{"path":"src/content/api","name":"api","children":[{"path":"src/content/api/index.mdx","name":"index.mdx","size":1888,"type":"file","extension":".mdx","url":"/api/","anchors":[{"title":"CLI","id":"cli","level":2},{"title":"Module","id":"module","level":2},{"title":"Node","id":"node","level":2},{"title":"Loaders","id":"loaders","level":2},{"title":"Plugins","id":"plugins","level":2}],"title":"Introduction","sort":-1,"contributors":["tbroadley"]},{"path":"src/content/api/cli.mdx","name":"cli.mdx","size":25994,"type":"file","extension":".mdx","url":"/api/cli/","anchors":[{"title":"Commands","id":"commands","level":2},{"title":"Build","id":"build","level":3},{"title":"Init","id":"init","level":3},{"title":"Loader","id":"loader","level":3},{"title":"Plugin","id":"plugin","level":3},{"title":"Info","id":"info","level":3},{"title":"Configtest","id":"configtest","level":3},{"title":"Serve","id":"serve","level":3},{"title":"Watch","id":"watch","level":3},{"title":"Flags","id":"flags","level":2},{"title":"Negated Flags","id":"negated-flags","level":3},{"title":"Core Flags","id":"core-flags","level":3},{"title":"Usage","id":"usage","level":2},{"title":"With configuration file","id":"with-configuration-file","level":3},{"title":"Without configuration file","id":"without-configuration-file","level":3},{"title":"Default Configurations","id":"default-configurations","level":2},{"title":"Common Options","id":"common-options","level":2},{"title":"help","id":"help","level":3},{"title":"version","id":"version","level":3},{"title":"config","id":"config","level":3},{"title":"config-name","id":"config-name","level":3},{"title":"merge","id":"merge","level":3},{"title":"extends","id":"extends","level":3},{"title":"json","id":"json","level":3},{"title":"Environment Options","id":"environment-options","level":2},{"title":"env","id":"env","level":3},{"title":"node-env","id":"node-env","level":3},{"title":"define-process-env-node-env","id":"define-process-env-node-env","level":3},{"title":"Configuration Options","id":"configuration-options","level":2},{"title":"Analyzing Bundle","id":"analyzing-bundle","level":2},{"title":"Progress","id":"progress","level":2},{"title":"Pass CLI arguments to Node.js","id":"pass-cli-arguments-to-nodejs","level":2},{"title":"Exit codes and their meanings","id":"exit-codes-and-their-meanings","level":2},{"title":"CLI Environment Variables","id":"cli-environment-variables","level":2},{"title":"WEBPACK_PACKAGE","id":"webpack_package","level":3},{"title":"Troubleshooting","id":"troubleshooting","level":2},{"title":"TypeError [ERR_UNKNOWN_FILE_EXTENSION]: Unknown file extension \\".ts\\" for ./webpack.config.ts","id":"typeerror-err_unknown_file_extension-unknown-file-extension-ts-for-webpackconfigts","level":3}],"title":"Command Line Interface","sort":1,"contributors":["anshumanv","rishabh3112","snitin315","evenstensberg","simon04","tbroadley","chenxsan","rencire","madhavarshney","EugeneHlushko","byzyk","wizardofhogwarts","EslamHiko","smelukov","anikethsaha","jamesgeorge007","burhanuday"],"related":[{"title":"Analyzing Build Statistics","url":"https://survivejs.com/webpack/optimizing-build/analyzing-build-statistics/"},{"title":"Three simple ways to inspect a webpack bundle","url":"https://medium.com/@joeclever/three-simple-ways-to-inspect-a-webpack-bundle-7f6a8fe7195d#.7d2i06mjx"},{"title":"Optimising your application bundle size with webpack","url":"https://hackernoon.com/optimising-your-application-bundle-size-with-webpack-e85b00bab579#.5w5ko08pq"},{"title":"Analysing and minimising the size of client-side bundle with webpack and source-map-explorer","url":"https://medium.com/@nimgrg/analysing-and-minimising-the-size-of-client-side-bundle-with-webpack-and-source-map-explorer-41096559beca#.c3t2srr8x"}]},{"path":"src/content/api/node.mdx","name":"node.mdx","size":9916,"type":"file","extension":".mdx","url":"/api/node/","anchors":[{"title":"Installation","id":"installation","level":2},{"title":"webpack()","id":"webpack","level":2},{"title":"Compiler Instance","id":"compiler-instance","level":2},{"title":"Run","id":"run","level":2},{"title":"Watching","id":"watching","level":2},{"title":"Close Watching","id":"close-watching","level":3},{"title":"Invalidate Watching","id":"invalidate-watching","level":3},{"title":"Stats Object","id":"stats-object","level":2},{"title":"stats.hasErrors()","id":"statshaserrors","level":3},{"title":"stats.hasWarnings()","id":"statshaswarnings","level":3},{"title":"stats.toJson(options)","id":"statstojsonoptions","level":3},{"title":"stats.toString(options)","id":"statstostringoptions","level":3},{"title":"MultiCompiler","id":"multicompiler","level":2},{"title":"Error Handling","id":"error-handling","level":2},{"title":"Custom File Systems","id":"custom-file-systems","level":2}],"title":"Node Interface","sort":2,"contributors":["sallar","rynclark","byzyk","wizardofhogwarts","EugeneHlushko","lukasgeiter","toshihidetagami","chenxsan","jamesgeorge007","textbook"]},{"path":"src/content/api/stats.mdx","name":"stats.mdx","size":11861,"type":"file","extension":".mdx","url":"/api/stats/","anchors":[{"title":"Structure","id":"structure","level":2},{"title":"Asset Objects","id":"asset-objects","level":3},{"title":"Chunk Objects","id":"chunk-objects","level":3},{"title":"Module Objects","id":"module-objects","level":3},{"title":"Entry Objects","id":"entry-objects","level":3},{"title":"Errors and Warnings","id":"errors-and-warnings","level":3}],"title":"Stats Data","sort":3,"contributors":["skipjack","franjohn21","byzyk","EugeneHlushko","superburrito","chenxsan","rahul3v","snitin315"]},{"path":"src/content/api/webpack-dev-server.mdx","name":"webpack-dev-server.mdx","size":4181,"type":"file","extension":".mdx","url":"/api/webpack-dev-server/","anchors":[{"title":"Installation","id":"installation","level":2},{"title":"start","id":"start","level":2},{"title":"startCallback(callback)","id":"startcallbackcallback","level":2},{"title":"stop","id":"stop","level":2},{"title":"stopCallback(callback)","id":"stopcallbackcallback","level":2},{"title":"internalIP(family: \\"v4\\" | \\"v6\\")","id":"internalipfamily-v4--v6","level":2},{"title":"internalIPSync(family: \\"v4\\" | \\"v6\\")","id":"internalipsyncfamily-v4--v6","level":2}],"title":"webpack-dev-server API","sort":3,"contributors":["snitin315"]},{"path":"src/content/api/hot-module-replacement.mdx","name":"hot-module-replacement.mdx","size":12482,"type":"file","extension":".mdx","url":"/api/hot-module-replacement/","anchors":[{"title":"Module API","id":"module-api","level":2},{"title":"accept","id":"accept","level":3},{"title":"accept (self)","id":"accept-self","level":3},{"title":"decline","id":"decline","level":3},{"title":"decline (self)","id":"decline-self","level":3},{"title":"dispose (or addDisposeHandler)","id":"dispose-or-adddisposehandler","level":3},{"title":"invalidate","id":"invalidate","level":3},{"title":"removeDisposeHandler","id":"removedisposehandler","level":3},{"title":"Management API","id":"management-api","level":2},{"title":"status","id":"status","level":3},{"title":"check","id":"check","level":3},{"title":"apply","id":"apply","level":3},{"title":"addStatusHandler","id":"addstatushandler","level":3},{"title":"removeStatusHandler","id":"removestatushandler","level":3}],"title":"Hot Module Replacement","sort":4,"contributors":["sokra","skipjack","tbroadley","byzyk","wizardofhogwarts","snitin315"],"related":[{"title":"Concepts - Hot Module Replacement","url":"/concepts/hot-module-replacement"},{"title":"Guides - Hot Module Replacement","url":"/guides/hot-module-replacement"}]},{"path":"src/content/api/loaders.mdx","name":"loaders.mdx","size":26784,"type":"file","extension":".mdx","url":"/api/loaders/","anchors":[{"title":"Examples","id":"examples","level":2},{"title":"Synchronous Loaders","id":"synchronous-loaders","level":3},{"title":"Asynchronous Loaders","id":"asynchronous-loaders","level":3},{"title":"\\"Raw\\" Loader","id":"raw-loader","level":3},{"title":"Pitching Loader","id":"pitching-loader","level":3},{"title":"The Loader Context","id":"the-loader-context","level":2},{"title":"Example for the loader context","id":"example-for-the-loader-context","level":3},{"title":"this.addContextDependency","id":"thisaddcontextdependency","level":3},{"title":"this.addDependency","id":"thisadddependency","level":3},{"title":"this.addMissingDependency","id":"thisaddmissingdependency","level":3},{"title":"this.async","id":"thisasync","level":3},{"title":"this.cacheable","id":"thiscacheable","level":3},{"title":"this.callback","id":"thiscallback","level":3},{"title":"this.clearDependencies","id":"thiscleardependencies","level":3},{"title":"this.context","id":"thiscontext","level":3},{"title":"this.data","id":"thisdata","level":3},{"title":"this.emitError","id":"thisemiterror","level":3},{"title":"this.emitFile","id":"thisemitfile","level":3},{"title":"this.emitWarning","id":"thisemitwarning","level":3},{"title":"this.environment","id":"thisenvironment","level":3},{"title":"this.fs","id":"thisfs","level":3},{"title":"this.getOptions(schema)","id":"thisgetoptionsschema","level":3},{"title":"this.getResolve","id":"thisgetresolve","level":3},{"title":"this.hot","id":"thishot","level":3},{"title":"this.importModule","id":"thisimportmodule","level":3},{"title":"this.loaderIndex","id":"thisloaderindex","level":3},{"title":"this.loadModule","id":"thisloadmodule","level":3},{"title":"this.loaders","id":"thisloaders","level":3},{"title":"this.mode","id":"thismode","level":3},{"title":"this.query","id":"thisquery","level":3},{"title":"this.request","id":"thisrequest","level":3},{"title":"this.resolve","id":"thisresolve","level":3},{"title":"this.resource","id":"thisresource","level":3},{"title":"this.resourcePath","id":"thisresourcepath","level":3},{"title":"this.resourceQuery","id":"thisresourcequery","level":3},{"title":"this.rootContext","id":"thisrootcontext","level":3},{"title":"this.sourceMap","id":"thissourcemap","level":3},{"title":"this.target","id":"thistarget","level":3},{"title":"this.utils","id":"thisutils","level":3},{"title":"this.version","id":"thisversion","level":3},{"title":"this.webpack","id":"thiswebpack","level":3},{"title":"Webpack specific properties","id":"webpack-specific-properties","level":2},{"title":"this._compilation","id":"this_compilation","level":3},{"title":"this._compiler","id":"this_compiler","level":3},{"title":"Deprecated context properties","id":"deprecated-context-properties","level":2},{"title":"this.debug","id":"thisdebug","level":3},{"title":"this.inputValue","id":"thisinputvalue","level":3},{"title":"this.minimize","id":"thisminimize","level":3},{"title":"this.value","id":"thisvalue","level":3},{"title":"this._module","id":"this_module","level":3},{"title":"Error Reporting","id":"error-reporting","level":2},{"title":"Inline matchResource","id":"inline-matchresource","level":2},{"title":"Logging","id":"logging","level":2}],"title":"Loader Interface","sort":5,"contributors":["TheLarkInn","jhnns","tbroadley","byzyk","sokra","EugeneHlushko","jantimon","superburrito","wizardofhogwarts","snitin315","chenxsan","jamesgeorge007"]},{"path":"src/content/api/logging.mdx","name":"logging.mdx","size":4597,"type":"file","extension":".mdx","url":"/api/logging/","anchors":[{"title":"Examples of how to get and use webpack logger in loaders and plugins","id":"examples-of-how-to-get-and-use-webpack-logger-in-loaders-and-plugins","level":2},{"title":"Logger methods","id":"logger-methods","level":2},{"title":"Runtime Logger API","id":"runtime-logger-api","level":2}],"title":"Logger Interface","sort":6,"contributors":["EugeneHlushko","wizardofhogwarts","chenxsan","snitin315"]},{"path":"src/content/api/module-methods.mdx","name":"module-methods.mdx","size":20293,"type":"file","extension":".mdx","url":"/api/module-methods/","anchors":[{"title":"ES6 (Recommended)","id":"es6-recommended","level":2},{"title":"import","id":"import","level":3},{"title":"export","id":"export","level":3},{"title":"import()","id":"import-1","level":3},{"title":"Dynamic expressions in import()","id":"dynamic-expressions-in-import","level":3},{"title":"CommonJS","id":"commonjs","level":2},{"title":"require","id":"require","level":3},{"title":"require.resolve","id":"requireresolve","level":3},{"title":"require.cache","id":"requirecache","level":3},{"title":"require.ensure","id":"requireensure","level":3},{"title":"AMD","id":"amd","level":2},{"title":"define (with factory)","id":"define-with-factory","level":3},{"title":"define (with value)","id":"define-with-value","level":3},{"title":"require (amd-version)","id":"require-amd-version","level":3},{"title":"Labeled Modules","id":"labeled-modules","level":2},{"title":"export label","id":"export-label","level":3},{"title":"require label","id":"require-label","level":3},{"title":"Webpack","id":"webpack","level":2},{"title":"require.context","id":"requirecontext","level":3},{"title":"require.include","id":"requireinclude","level":3},{"title":"require.resolveWeak","id":"requireresolveweak","level":3},{"title":"warning","id":"warning","level":3}],"title":"Module Methods","group":"Modules","sort":7,"contributors":["skipjack","sokra","fadysamirsadek","byzyk","debs-obrien","wizardofhogwarts","EugeneHlushko","chenxsan","jamesgeorge007","WofWca"],"related":[{"title":"CommonJS Wikipedia","url":"https://en.wikipedia.org/wiki/CommonJS"},{"title":"Asynchronous Module Definition","url":"https://en.wikipedia.org/wiki/Asynchronous_module_definition"}]},{"path":"src/content/api/module-variables.mdx","name":"module-variables.mdx","size":8539,"type":"file","extension":".mdx","url":"/api/module-variables/","anchors":[{"title":"module.loaded (NodeJS)","id":"moduleloaded-nodejs","level":2},{"title":"module.hot (webpack-specific)","id":"modulehot-webpack-specific","level":2},{"title":"module.id (CommonJS)","id":"moduleid-commonjs","level":2},{"title":"module.exports (CommonJS)","id":"moduleexports-commonjs","level":2},{"title":"exports (CommonJS)","id":"exports-commonjs","level":2},{"title":"global (NodeJS)","id":"global-nodejs","level":2},{"title":"__dirname (NodeJS)","id":"__dirname-nodejs","level":2},{"title":"import.meta","id":"importmeta","level":2},{"title":"import.meta.url","id":"importmetaurl","level":3},{"title":"import.meta.webpack","id":"importmetawebpack","level":3},{"title":"import.meta.webpackHot","id":"importmetawebpackhot","level":3},{"title":"import.meta.webpackContext","id":"importmetawebpackcontext","level":3},{"title":"__filename (NodeJS)","id":"__filename-nodejs","level":2},{"title":"__resourceQuery (webpack-specific)","id":"__resourcequery-webpack-specific","level":2},{"title":"__webpack_public_path__ (webpack-specific)","id":"__webpack_public_path__-webpack-specific","level":2},{"title":"__webpack_require__ (webpack-specific)","id":"__webpack_require__-webpack-specific","level":2},{"title":"__webpack_chunk_load__ (webpack-specific)","id":"__webpack_chunk_load__-webpack-specific","level":2},{"title":"__webpack_module__ (webpack-specific)","id":"__webpack_module__-webpack-specific","level":2},{"title":"__webpack_module__.id (webpack-specific)","id":"__webpack_module__id-webpack-specific","level":2},{"title":"__webpack_modules__ (webpack-specific)","id":"__webpack_modules__-webpack-specific","level":2},{"title":"__webpack_hash__ (webpack-specific)","id":"__webpack_hash__-webpack-specific","level":2},{"title":"__webpack_get_script_filename__ (webpack-specific)","id":"__webpack_get_script_filename__-webpack-specific","level":2},{"title":"__non_webpack_require__ (webpack-specific)","id":"__non_webpack_require__-webpack-specific","level":2},{"title":"__webpack_exports_info__ (webpack-specific)","id":"__webpack_exports_info__-webpack-specific","level":2},{"title":"__webpack_is_included__ (webpack-specific)","id":"__webpack_is_included__-webpack-specific","level":2},{"title":"__webpack_base_uri__ (webpack-specific)","id":"__webpack_base_uri__-webpack-specific","level":2},{"title":"__webpack_runtime_id__","id":"__webpack_runtime_id__","level":2},{"title":"DEBUG (webpack-specific)","id":"debug-webpack-specific","level":2}],"title":"Module Variables","group":"Modules","sort":8,"contributors":["skipjack","sokra","ahmehri","tbroadley","byzyk","EugeneHlushko","wizardofhogwarts","anikethsaha","chenxsan","jamesgeorge007","snitin315"],"related":[{"title":"CommonJS","url":"https://en.wikipedia.org/wiki/CommonJS"},{"title":"Asynchronous Module Definition","url":"https://en.wikipedia.org/wiki/Asynchronous_module_definition"}]},{"path":"src/content/api/compilation-object.mdx","name":"compilation-object.mdx","size":7134,"type":"file","extension":".mdx","url":"/api/compilation-object/","anchors":[{"title":"compilation object methods","id":"compilation-object-methods","level":2},{"title":"getStats","id":"getstats","level":3},{"title":"addModule","id":"addmodule","level":3},{"title":"getModule","id":"getmodule","level":3},{"title":"findModule","id":"findmodule","level":3},{"title":"buildModule","id":"buildmodule","level":3},{"title":"processModuleDependencies","id":"processmoduledependencies","level":3},{"title":"addEntry","id":"addentry","level":3},{"title":"rebuildModule","id":"rebuildmodule","level":3},{"title":"finish","id":"finish","level":3},{"title":"seal","id":"seal","level":3},{"title":"unseal","id":"unseal","level":3},{"title":"reportDependencyErrorsAndWarnings","id":"reportdependencyerrorsandwarnings","level":3},{"title":"addChunkInGroup","id":"addchunkingroup","level":3},{"title":"addChunk","id":"addchunk","level":3},{"title":"assignDepth","id":"assigndepth","level":3},{"title":"getDependencyReference","id":"getdependencyreference","level":3},{"title":"processDependenciesBlocksForChunkGroups","id":"processdependenciesblocksforchunkgroups","level":3},{"title":"removeReasonsOfDependencyBlock","id":"removereasonsofdependencyblock","level":3},{"title":"patchChunksAfterReasonRemoval","id":"patchchunksafterreasonremoval","level":3},{"title":"removeChunkFromDependencies","id":"removechunkfromdependencies","level":3},{"title":"sortItemsWithChunkIds","id":"sortitemswithchunkids","level":3},{"title":"summarizeDependencies","id":"summarizedependencies","level":3},{"title":"createHash","id":"createhash","level":3},{"title":"createModuleAssets","id":"createmoduleassets","level":3},{"title":"createChunkAssets","id":"createchunkassets","level":3},{"title":"getPath","id":"getpath","level":3},{"title":"getPathWithInfo","id":"getpathwithinfo","level":3},{"title":"createChildCompiler","id":"createchildcompiler","level":3},{"title":"checkConstraints","id":"checkconstraints","level":3},{"title":"emitAsset","id":"emitasset","level":3},{"title":"updateAsset","id":"updateasset","level":3},{"title":"deleteAsset","id":"deleteasset","level":3},{"title":"getAssets","id":"getassets","level":3},{"title":"getAsset","id":"getasset","level":3}],"title":"Compilation Object","group":"Objects","sort":14,"contributors":["EugeneHlushko","wizardofhogwarts","jamesgeorge007","snitin315"]},{"path":"src/content/api/compiler-hooks.mdx","name":"compiler-hooks.mdx","size":6946,"type":"file","extension":".mdx","url":"/api/compiler-hooks/","anchors":[{"title":"Watching","id":"watching","level":2},{"title":"Hooks","id":"hooks","level":2},{"title":"environment","id":"environment","level":3},{"title":"afterEnvironment","id":"afterenvironment","level":3},{"title":"entryOption","id":"entryoption","level":3},{"title":"afterPlugins","id":"afterplugins","level":3},{"title":"afterResolvers","id":"afterresolvers","level":3},{"title":"initialize","id":"initialize","level":3},{"title":"beforeRun","id":"beforerun","level":3},{"title":"run","id":"run","level":3},{"title":"watchRun","id":"watchrun","level":3},{"title":"normalModuleFactory","id":"normalmodulefactory","level":3},{"title":"contextModuleFactory","id":"contextmodulefactory","level":3},{"title":"beforeCompile","id":"beforecompile","level":3},{"title":"compile","id":"compile","level":3},{"title":"thisCompilation","id":"thiscompilation","level":3},{"title":"compilation","id":"compilation","level":3},{"title":"make","id":"make","level":3},{"title":"afterCompile","id":"aftercompile","level":3},{"title":"shouldEmit","id":"shouldemit","level":3},{"title":"emit","id":"emit","level":3},{"title":"afterEmit","id":"afteremit","level":3},{"title":"assetEmitted","id":"assetemitted","level":3},{"title":"done","id":"done","level":3},{"title":"additionalPass","id":"additionalpass","level":3},{"title":"failed","id":"failed","level":3},{"title":"invalid","id":"invalid","level":3},{"title":"watchClose","id":"watchclose","level":3},{"title":"shutdown","id":"shutdown","level":3},{"title":"infrastructureLog","id":"infrastructurelog","level":3},{"title":"log","id":"log","level":3}],"title":"Compiler Hooks","group":"Plugins","sort":9,"contributors":["rishantagarwal","byzyk","madhavarshney","misterdev","EugeneHlushko","superburrito","chenxsan"]},{"path":"src/content/api/compilation-hooks.mdx","name":"compilation-hooks.mdx","size":15807,"type":"file","extension":".mdx","url":"/api/compilation-hooks/","anchors":[{"title":"buildModule","id":"buildmodule","level":3},{"title":"rebuildModule","id":"rebuildmodule","level":3},{"title":"failedModule","id":"failedmodule","level":3},{"title":"succeedModule","id":"succeedmodule","level":3},{"title":"finishModules","id":"finishmodules","level":3},{"title":"finishRebuildingModule","id":"finishrebuildingmodule","level":3},{"title":"seal","id":"seal","level":3},{"title":"unseal","id":"unseal","level":3},{"title":"optimizeDependencies","id":"optimizedependencies","level":3},{"title":"afterOptimizeDependencies","id":"afteroptimizedependencies","level":3},{"title":"afterChunks","id":"afterchunks","level":3},{"title":"optimize","id":"optimize","level":3},{"title":"optimizeModules","id":"optimizemodules","level":3},{"title":"afterOptimizeModules","id":"afteroptimizemodules","level":3},{"title":"optimizeChunks","id":"optimizechunks","level":3},{"title":"afterOptimizeChunks","id":"afteroptimizechunks","level":3},{"title":"optimizeTree","id":"optimizetree","level":3},{"title":"afterOptimizeTree","id":"afteroptimizetree","level":3},{"title":"optimizeChunkModules","id":"optimizechunkmodules","level":3},{"title":"afterOptimizeChunkModules","id":"afteroptimizechunkmodules","level":3},{"title":"shouldRecord","id":"shouldrecord","level":3},{"title":"reviveModules","id":"revivemodules","level":3},{"title":"beforeModuleIds","id":"beforemoduleids","level":3},{"title":"moduleIds","id":"moduleids","level":3},{"title":"optimizeModuleIds","id":"optimizemoduleids","level":3},{"title":"afterOptimizeModuleIds","id":"afteroptimizemoduleids","level":3},{"title":"reviveChunks","id":"revivechunks","level":3},{"title":"beforeChunkIds","id":"beforechunkids","level":3},{"title":"chunkIds","id":"chunkids","level":3},{"title":"optimizeChunkIds","id":"optimizechunkids","level":3},{"title":"afterOptimizeChunkIds","id":"afteroptimizechunkids","level":3},{"title":"recordModules","id":"recordmodules","level":3},{"title":"recordChunks","id":"recordchunks","level":3},{"title":"beforeModuleHash","id":"beforemodulehash","level":3},{"title":"afterModuleHash","id":"aftermodulehash","level":3},{"title":"beforeHash","id":"beforehash","level":3},{"title":"afterHash","id":"afterhash","level":3},{"title":"recordHash","id":"recordhash","level":3},{"title":"record","id":"record","level":3},{"title":"beforeModuleAssets","id":"beforemoduleassets","level":3},{"title":"additionalChunkAssets","id":"additionalchunkassets","level":3},{"title":"shouldGenerateChunkAssets","id":"shouldgeneratechunkassets","level":3},{"title":"beforeChunkAssets","id":"beforechunkassets","level":3},{"title":"additionalAssets","id":"additionalassets","level":3},{"title":"optimizeChunkAssets","id":"optimizechunkassets","level":3},{"title":"afterOptimizeChunkAssets","id":"afteroptimizechunkassets","level":3},{"title":"optimizeAssets","id":"optimizeassets","level":3},{"title":"afterOptimizeAssets","id":"afteroptimizeassets","level":3},{"title":"processAssets","id":"processassets","level":3},{"title":"afterProcessAssets","id":"afterprocessassets","level":3},{"title":"needAdditionalSeal","id":"needadditionalseal","level":3},{"title":"afterSeal","id":"afterseal","level":3},{"title":"chunkHash","id":"chunkhash","level":3},{"title":"moduleAsset","id":"moduleasset","level":3},{"title":"chunkAsset","id":"chunkasset","level":3},{"title":"assetPath","id":"assetpath","level":3},{"title":"needAdditionalPass","id":"needadditionalpass","level":3},{"title":"childCompiler","id":"childcompiler","level":3},{"title":"normalModuleLoader","id":"normalmoduleloader","level":3}],"title":"Compilation Hooks","group":"Plugins","sort":10,"contributors":["slavafomin","byzyk","madhavarshney","misterdev","wizardofhogwarts","EugeneHlushko","chenxsan","jamesgeorge007"]},{"path":"src/content/api/contextmodulefactory-hooks.mdx","name":"contextmodulefactory-hooks.mdx","size":1531,"type":"file","extension":".mdx","url":"/api/contextmodulefactory-hooks/","anchors":[{"title":"beforeResolve","id":"beforeresolve","level":3},{"title":"afterResolve","id":"afterresolve","level":3},{"title":"contextModuleFiles","id":"contextmodulefiles","level":3},{"title":"alternativeRequests","id":"alternativerequests","level":3}],"title":"ContextModuleFactory Hooks","group":"Plugins","sort":11,"contributors":["iguessitsokay"]},{"path":"src/content/api/parser.mdx","name":"parser.mdx","size":9932,"type":"file","extension":".mdx","url":"/api/parser/","anchors":[{"title":"Hooks","id":"hooks","level":2},{"title":"evaluateTypeof","id":"evaluatetypeof","level":3},{"title":"evaluate","id":"evaluate","level":3},{"title":"evaluateIdentifier","id":"evaluateidentifier","level":3},{"title":"evaluateDefinedIdentifier","id":"evaluatedefinedidentifier","level":3},{"title":"evaluateCallExpressionMember","id":"evaluatecallexpressionmember","level":3},{"title":"statement","id":"statement","level":3},{"title":"statementIf","id":"statementif","level":3},{"title":"label","id":"label","level":3},{"title":"import","id":"import","level":3},{"title":"importSpecifier","id":"importspecifier","level":3},{"title":"export","id":"export","level":3},{"title":"exportImport","id":"exportimport","level":3},{"title":"exportDeclaration","id":"exportdeclaration","level":3},{"title":"exportExpression","id":"exportexpression","level":3},{"title":"exportSpecifier","id":"exportspecifier","level":3},{"title":"exportImportSpecifier","id":"exportimportspecifier","level":3},{"title":"varDeclaration","id":"vardeclaration","level":3},{"title":"varDeclarationLet","id":"vardeclarationlet","level":3},{"title":"varDeclarationConst","id":"vardeclarationconst","level":3},{"title":"varDeclarationVar","id":"vardeclarationvar","level":3},{"title":"canRename","id":"canrename","level":3},{"title":"rename","id":"rename","level":3},{"title":"assigned","id":"assigned","level":3},{"title":"assign","id":"assign","level":3},{"title":"typeof","id":"typeof","level":3},{"title":"call","id":"call","level":3},{"title":"callMemberChain","id":"callmemberchain","level":3},{"title":"new","id":"new","level":3},{"title":"expression","id":"expression","level":3},{"title":"expressionConditionalOperator","id":"expressionconditionaloperator","level":3},{"title":"program","id":"program","level":3}],"title":"JavascriptParser Hooks","group":"Plugins","sort":12,"contributors":["byzyk","DeTeam","misterdev","EugeneHlushko","chenxsan"]},{"path":"src/content/api/normalmodulefactory-hooks.mdx","name":"normalmodulefactory-hooks.mdx","size":3784,"type":"file","extension":".mdx","url":"/api/normalmodulefactory-hooks/","anchors":[{"title":"beforeResolve","id":"beforeresolve","level":3},{"title":"factorize","id":"factorize","level":3},{"title":"resolve","id":"resolve","level":3},{"title":"resolveForScheme","id":"resolveforscheme","level":3},{"title":"afterResolve","id":"afterresolve","level":3},{"title":"createModule","id":"createmodule","level":3},{"title":"createModuleClass","id":"createmoduleclass","level":3},{"title":"module","id":"module","level":3},{"title":"createParser","id":"createparser","level":3},{"title":"parser","id":"parser","level":3},{"title":"createGenerator","id":"creategenerator","level":3},{"title":"generator","id":"generator","level":3}],"title":"NormalModuleFactory Hooks","group":"Plugins","sort":13,"contributors":["iguessitsokay","chenxsan"]},{"path":"src/content/api/plugins.mdx","name":"plugins.mdx","size":6988,"type":"file","extension":".mdx","url":"/api/plugins/","anchors":[{"title":"Tapable","id":"tapable","level":2},{"title":"Plugin Types","id":"plugin-types","level":2},{"title":"Custom Hooks","id":"custom-hooks","level":2},{"title":"Reporting Progress","id":"reporting-progress","level":2},{"title":"Logging","id":"logging","level":2},{"title":"Next Steps","id":"next-steps","level":2}],"title":"Plugin API","group":"Plugins","sort":14,"contributors":["thelarkinn","pksjce","e-cloud","byzyk","EugeneHlushko","wizardofhogwarts","snitin315"]},{"path":"src/content/api/resolvers.mdx","name":"resolvers.mdx","size":2183,"type":"file","extension":".mdx","url":"/api/resolvers/","anchors":[{"title":"Types","id":"types","level":2},{"title":"Configuration Options","id":"configuration-options","level":2}],"title":"Resolvers","group":"Plugins","sort":15,"contributors":["EugeneHlushko","chenxsan"]}],"size":180840,"type":"directory","url":"/api/"},{"path":"src/content/blog","name":"blog","children":[{"path":"src/content/blog/2020-12-08-roadmap-2021.mdx","name":"2020-12-08-roadmap-2021.mdx","size":16371,"type":"file","extension":".mdx","url":"/blog/2020-12-08-roadmap-2021/","anchors":[{"title":"What happened so far?","id":"what-happened-so-far","level":2},{"title":"Roadmap 2021","id":"roadmap-2021","level":2},{"title":"Further stabilizing","id":"further-stabilizing","level":3},{"title":"EcmaScript Modules","id":"ecmascript-modules","level":3},{"title":"More first-class citizen","id":"more-first-class-citizen","level":3},{"title":"SourceMap performance","id":"sourcemap-performance","level":3},{"title":"exports/imports package.json field","id":"exportsimports-packagejson-field","level":3},{"title":"Improve CommonJS analysis","id":"improve-commonjs-analysis","level":3},{"title":"Hot Module Replacement for Module Federation","id":"hot-module-replacement-for-module-federation","level":3},{"title":"Hinting system","id":"hinting-system","level":3},{"title":"Multi-Threading","id":"multi-threading","level":3},{"title":"WebAssembly","id":"webassembly","level":3},{"title":"Disclaimer","id":"disclaimer","level":2}],"title":"Roadmap 2021 (2020-12-08)","sort":-202012080,"contributors":["sokra"]},{"path":"src/content/blog/2020-10-10-webpack-5-release.mdx","name":"2020-10-10-webpack-5-release.mdx","size":71620,"type":"file","extension":".mdx","url":"/blog/2020-10-10-webpack-5-release/","anchors":[{"title":"Common Questions","id":"common-questions","level":2},{"title":"So what does the release mean?","id":"so-what-does-the-release-mean","level":3},{"title":"So when is the time to upgrade?","id":"so-when-is-the-time-to-upgrade","level":3},{"title":"Sponsoring Update","id":"sponsoring-update","level":2},{"title":"General direction","id":"general-direction","level":2},{"title":"Migration Guide","id":"migration-guide","level":2},{"title":"Major Changes: Removals","id":"major-changes-removals","level":2},{"title":"Removed Deprecated Items","id":"removed-deprecated-items","level":3},{"title":"Deprecation codes","id":"deprecation-codes","level":3},{"title":"Syntax deprecated","id":"syntax-deprecated","level":3},{"title":"Automatic Node.js Polyfills Removed","id":"automatic-nodejs-polyfills-removed","level":3},{"title":"Major Changes: Long Term Caching","id":"major-changes-long-term-caching","level":2},{"title":"Deterministic Chunk, Module IDs and Export names","id":"deterministic-chunk-module-ids-and-export-names","level":3},{"title":"Real Content Hash","id":"real-content-hash","level":3},{"title":"Major Changes: Development Support","id":"major-changes-development-support","level":2},{"title":"Named Chunk IDs","id":"named-chunk-ids","level":3},{"title":"Module Federation","id":"module-federation","level":3},{"title":"Major Changes: New Web Platform Features","id":"major-changes-new-web-platform-features","level":2},{"title":"JSON modules","id":"json-modules","level":3},{"title":"import.meta","id":"importmeta","level":3},{"title":"Asset modules","id":"asset-modules","level":3},{"title":"Native Worker support","id":"native-worker-support","level":3},{"title":"URIs","id":"uris","level":3},{"title":"Async modules","id":"async-modules","level":3},{"title":"Externals","id":"externals","level":3},{"title":"Major Changes: New Node.js Ecosystem Features","id":"major-changes-new-nodejs-ecosystem-features","level":2},{"title":"Resolving","id":"resolving","level":3},{"title":"Major Changes: Development Experience","id":"major-changes-development-experience","level":2},{"title":"Improved target","id":"improved-target","level":3},{"title":"Stats","id":"stats","level":3},{"title":"Progress","id":"progress","level":3},{"title":"Automatic unique naming","id":"automatic-unique-naming","level":3},{"title":"Automatic public path","id":"automatic-public-path","level":3},{"title":"Typescript typings","id":"typescript-typings","level":3},{"title":"Major Changes: Optimization","id":"major-changes-optimization","level":2},{"title":"Nested tree-shaking","id":"nested-tree-shaking","level":3},{"title":"Inner-module tree-shaking","id":"inner-module-tree-shaking","level":3},{"title":"CommonJs Tree Shaking","id":"commonjs-tree-shaking","level":3},{"title":"Side-Effect analysis","id":"side-effect-analysis","level":3},{"title":"Optimization per runtime","id":"optimization-per-runtime","level":3},{"title":"Module Concatenation","id":"module-concatenation","level":3},{"title":"General Tree Shaking improvements","id":"general-tree-shaking-improvements","level":3},{"title":"Development Production Similarity","id":"development-production-similarity","level":3},{"title":"Improved Code Generation","id":"improved-code-generation","level":3},{"title":"Improved target option","id":"improved-target-option","level":3},{"title":"SplitChunks and Module Sizes","id":"splitchunks-and-module-sizes","level":3},{"title":"Major Changes: Performance","id":"major-changes-performance","level":2},{"title":"Persistent Caching","id":"persistent-caching","level":3},{"title":"File Emitting","id":"file-emitting","level":3},{"title":"Major Changes: Long outstanding problems","id":"major-changes-long-outstanding-problems","level":2},{"title":"Code Splitting for single-file-targets","id":"code-splitting-for-single-file-targets","level":3},{"title":"Updated Resolver","id":"updated-resolver","level":3},{"title":"Chunks without JS","id":"chunks-without-js","level":3},{"title":"Major Changes: Future","id":"major-changes-future","level":2},{"title":"Experiments","id":"experiments","level":3},{"title":"Minimum Node.js Version","id":"minimum-nodejs-version","level":3},{"title":"Changes to the Configuration","id":"changes-to-the-configuration","level":2},{"title":"Changes to the Structure","id":"changes-to-the-structure","level":3},{"title":"Changes to the Defaults","id":"changes-to-the-defaults","level":3},{"title":"Loader related Changes","id":"loader-related-changes","level":2},{"title":"this.getOptions","id":"thisgetoptions","level":3},{"title":"this.exec","id":"thisexec","level":3},{"title":"this.getResolve","id":"thisgetresolve","level":3},{"title":"Major Internal Changes","id":"major-internal-changes","level":2},{"title":"New plugin order","id":"new-plugin-order","level":3},{"title":"Runtime Modules","id":"runtime-modules","level":3},{"title":"Serialization","id":"serialization","level":3},{"title":"Plugins for Caching","id":"plugins-for-caching","level":3},{"title":"Hook Object Frozen","id":"hook-object-frozen","level":3},{"title":"Tapable Upgrade","id":"tapable-upgrade","level":3},{"title":"Staged Hooks","id":"staged-hooks","level":3},{"title":"Main/Chunk/ModuleTemplate deprecation","id":"mainchunkmoduletemplate-deprecation","level":3},{"title":"Entry point descriptor","id":"entry-point-descriptor","level":3},{"title":"Order and IDs","id":"order-and-ids","level":3},{"title":"Arrays to Sets","id":"arrays-to-sets","level":3},{"title":"Compilation.fileSystemInfo","id":"compilationfilesysteminfo","level":3},{"title":"Filesystems","id":"filesystems","level":3},{"title":"Hot Module Replacement","id":"hot-module-replacement","level":3},{"title":"Work Queues","id":"work-queues","level":3},{"title":"Logging","id":"logging","level":3},{"title":"Module and Chunk Graph","id":"module-and-chunk-graph","level":3},{"title":"Init Fragments","id":"init-fragments","level":3},{"title":"Module Source Types","id":"module-source-types","level":3},{"title":"Plugins for Stats","id":"plugins-for-stats","level":3},{"title":"New Watching","id":"new-watching","level":3},{"title":"SizeOnlySource after emit","id":"sizeonlysource-after-emit","level":3},{"title":"Emitting assets multiple times","id":"emitting-assets-multiple-times","level":3},{"title":"ExportsInfo","id":"exportsinfo","level":3},{"title":"Code Generation Phase","id":"code-generation-phase","level":3},{"title":"DependencyReference","id":"dependencyreference","level":3},{"title":"Presentational Dependencies","id":"presentational-dependencies","level":3},{"title":"Deprecated loaders","id":"deprecated-loaders","level":3},{"title":"Minor Changes","id":"minor-changes","level":2},{"title":"Other Minor Changes","id":"other-minor-changes","level":2}],"title":"Webpack 5 release (2020-10-10)","sort":-202010100,"contributors":["sokra","chenxsan"]},{"path":"src/content/blog/index.mdx","name":"index.mdx","size":214,"type":"file","extension":".mdx","url":"/blog/","anchors":[{"title":"Popular posts","id":"popular-posts","level":2}],"title":"Blog","sort":-1,"contributors":["sokra"]}],"size":88205,"type":"directory","url":"/blog/"},{"path":"src/content/concepts","name":"concepts","children":[{"path":"src/content/concepts/index.mdx","name":"index.mdx","size":7732,"type":"file","extension":".mdx","url":"/concepts/","anchors":[{"title":"Entry","id":"entry","level":2},{"title":"Output","id":"output","level":2},{"title":"Loaders","id":"loaders","level":2},{"title":"Plugins","id":"plugins","level":2},{"title":"Mode","id":"mode","level":2},{"title":"Browser Compatibility","id":"browser-compatibility","level":2},{"title":"Environment","id":"environment","level":2}],"title":"Concepts","sort":-1,"contributors":["TheLarkInn","jhnns","grgur","johnstew","jimrfenner","TheDutchCoder","adambraimbridge","EugeneHlushko","jeremenichelli","arjunsajeev","byzyk","yairhaimo","farskid","LukeMwila","Jalitha","muhmushtaha","chenxsan","RyanGreyling2"]},{"path":"src/content/concepts/entry-points.mdx","name":"entry-points.mdx","size":6616,"type":"file","extension":".mdx","url":"/concepts/entry-points/","anchors":[{"title":"Single Entry (Shorthand) Syntax","id":"single-entry-shorthand-syntax","level":2},{"title":"Object Syntax","id":"object-syntax","level":2},{"title":"EntryDescription object","id":"entrydescription-object","level":3},{"title":"Scenarios","id":"scenarios","level":2},{"title":"Separate App and Vendor Entries","id":"separate-app-and-vendor-entries","level":3},{"title":"Multi-Page Application","id":"multi-page-application","level":3}],"title":"Entry Points","sort":1,"contributors":["TheLarkInn","chrisVillanueva","byzyk","sokra","EugeneHlushko","Zearin","chenxsan","adyjs","anshumanv","ritikbanger"]},{"path":"src/content/concepts/output.mdx","name":"output.mdx","size":1840,"type":"file","extension":".mdx","url":"/concepts/output/","anchors":[{"title":"Usage","id":"usage","level":2},{"title":"Multiple Entry Points","id":"multiple-entry-points","level":2},{"title":"Advanced","id":"advanced","level":2}],"title":"Output","sort":2,"contributors":["TheLarkInn","chyipin","rouzbeh84","byzyk","EugeneHlushko"]},{"path":"src/content/concepts/loaders.mdx","name":"loaders.mdx","size":5546,"type":"file","extension":".mdx","url":"/concepts/loaders/","anchors":[{"title":"Example","id":"example","level":2},{"title":"Using Loaders","id":"using-loaders","level":2},{"title":"Configuration","id":"configuration","level":3},{"title":"Inline","id":"inline","level":3},{"title":"Loader Features","id":"loader-features","level":2},{"title":"Resolving Loaders","id":"resolving-loaders","level":2}],"title":"Loaders","sort":3,"contributors":["manekinekko","evenstensberg","SpaceK33z","gangachris","TheLarkInn","simon04","jhnns","byzyk","debs-obrien","EugeneHlushko","wizardofhogwarts","lukasgeiter","furkle","jamesgeorge007","textbook"]},{"path":"src/content/concepts/plugins.mdx","name":"plugins.mdx","size":3373,"type":"file","extension":".mdx","url":"/concepts/plugins/","anchors":[{"title":"Anatomy","id":"anatomy","level":2},{"title":"Usage","id":"usage","level":2},{"title":"Configuration","id":"configuration","level":3},{"title":"Node API","id":"node-api","level":3}],"title":"Plugins","sort":4,"contributors":["TheLarkInn","jhnns","rouzbeh84","johnstew","MisterDev","byzyk","chenxsan"]},{"path":"src/content/concepts/configuration.mdx","name":"configuration.mdx","size":2448,"type":"file","extension":".mdx","url":"/concepts/configuration/","anchors":[{"title":"Introductory Configuration","id":"introductory-configuration","level":2},{"title":"Multiple Targets","id":"multiple-targets","level":2},{"title":"Using other Configuration Languages","id":"using-other-configuration-languages","level":2}],"title":"Configuration","sort":5,"contributors":["TheLarkInn","simon04","EugeneHlushko","byzyk"]},{"path":"src/content/concepts/modules.mdx","name":"modules.mdx","size":2898,"type":"file","extension":".mdx","url":"/concepts/modules/","anchors":[{"title":"What is a webpack Module","id":"what-is-a-webpack-module","level":2},{"title":"Supported Module Types","id":"supported-module-types","level":2}],"title":"Modules","sort":6,"contributors":["TheLarkInn","simon04","rouzbeh84","EugeneHlushko","byzyk"],"related":[{"title":"JavaScript Module Systems Showdown","url":"https://auth0.com/blog/javascript-module-systems-showdown/"}]},{"path":"src/content/concepts/module-resolution.mdx","name":"module-resolution.mdx","size":4080,"type":"file","extension":".mdx","url":"/concepts/module-resolution/","anchors":[{"title":"Resolving rules in webpack","id":"resolving-rules-in-webpack","level":2},{"title":"Absolute paths","id":"absolute-paths","level":3},{"title":"Relative paths","id":"relative-paths","level":3},{"title":"Module paths","id":"module-paths","level":3},{"title":"Resolving Loaders","id":"resolving-loaders","level":2},{"title":"Caching","id":"caching","level":2}],"title":"Module Resolution","sort":7,"contributors":["pksjce","pastelsky","byzyk","EugeneHlushko","wizardofhogwarts"]},{"path":"src/content/concepts/module-federation.mdx","name":"module-federation.mdx","size":14602,"type":"file","extension":".mdx","url":"/concepts/module-federation/","anchors":[{"title":"Motivation","id":"motivation","level":2},{"title":"Low-level concepts","id":"low-level-concepts","level":2},{"title":"High-level concepts","id":"high-level-concepts","level":2},{"title":"Building blocks","id":"building-blocks","level":2},{"title":"ContainerPlugin (low level)","id":"containerplugin-low-level","level":3},{"title":"ContainerReferencePlugin (low level)","id":"containerreferenceplugin-low-level","level":3},{"title":"ModuleFederationPlugin (high level)","id":"modulefederationplugin-high-level","level":3},{"title":"Concept goals","id":"concept-goals","level":2},{"title":"Use cases","id":"use-cases","level":2},{"title":"Separate builds per page","id":"separate-builds-per-page","level":3},{"title":"Components library as container","id":"components-library-as-container","level":3},{"title":"Dynamic Remote Containers","id":"dynamic-remote-containers","level":2},{"title":"Promise Based Dynamic Remotes","id":"promise-based-dynamic-remotes","level":2},{"title":"Dynamic Public Path","id":"dynamic-public-path","level":2},{"title":"Offer a host API to set the publicPath","id":"offer-a-host-api-to-set-the-publicpath","level":3},{"title":"Infer publicPath from script","id":"infer-publicpath-from-script","level":3},{"title":"Troubleshooting","id":"troubleshooting","level":2},{"title":"Uncaught Error: Shared module is not available for eager consumption","id":"uncaught-error-shared-module-is-not-available-for-eager-consumption","level":3},{"title":"Uncaught Error: Module \\"./Button\\" does not exist in container.","id":"uncaught-error-module-button-does-not-exist-in-container","level":3},{"title":"Uncaught TypeError: fn is not a function","id":"uncaught-typeerror-fn-is-not-a-function","level":3},{"title":"Collision between modules from different remotes","id":"collision-between-modules-from-different-remotes","level":3}],"title":"Module Federation","sort":8,"contributors":["sokra","chenxsan","EugeneHlushko","jamesgeorge007","ScriptedAlchemy","snitin315","XiaofengXie16","KyleBastien","Alevale","burhanuday"],"related":[{"title":"Webpack 5 Module Federation: A game-changer in JavaScript architecture","url":"https://medium.com/swlh/webpack-5-module-federation-a-game-changer-to-javascript-architecture-bcdd30e02669"},{"title":"Explanations and Examples","url":"https://github.com/module-federation/module-federation-examples"},{"title":"Module Federation YouTube Playlist","url":"https://www.youtube.com/playlist?list=PLWSiF9YHHK-DqsFHGYbeAMwbd9xcZbEWJ"}]},{"path":"src/content/concepts/dependency-graph.mdx","name":"dependency-graph.mdx","size":1223,"type":"file","extension":".mdx","url":"/concepts/dependency-graph/","anchors":[],"title":"Dependency Graph","sort":9,"contributors":["TheLarkInn","EugeneHlushko"],"related":[{"title":"HTTP2 Aggressive Splitting Example","url":"https://github.com/webpack/webpack/tree/master/examples/http2-aggressive-splitting"},{"title":"webpack & HTTP/2","url":"https://medium.com/webpack/webpack-http-2-7083ec3f3ce6"}]},{"path":"src/content/concepts/targets.mdx","name":"targets.mdx","size":2462,"type":"file","extension":".mdx","url":"/concepts/targets/","anchors":[{"title":"Usage","id":"usage","level":2},{"title":"Multiple Targets","id":"multiple-targets","level":2},{"title":"Resources","id":"resources","level":2}],"title":"Targets","sort":10,"contributors":["TheLarkInn","rouzbeh84","johnstew","srilman","byzyk","EugeneHlushko"]},{"path":"src/content/concepts/manifest.mdx","name":"manifest.mdx","size":3393,"type":"file","extension":".mdx","url":"/concepts/manifest/","anchors":[{"title":"Runtime","id":"runtime","level":2},{"title":"Manifest","id":"manifest","level":2},{"title":"The Problem","id":"the-problem","level":2}],"title":"The Manifest","sort":11,"contributors":["skipjack","EugeneHlushko"],"related":[{"title":"Separating a Manifest","url":"https://survivejs.com/webpack/optimizing/separating-manifest/"},{"title":"Predictable Long Term Caching with webpack","url":"https://medium.com/webpack/predictable-long-term-caching-with-webpack-d3eee1d3fa31"},{"title":"Caching","url":"/guides/caching/"}]},{"path":"src/content/concepts/hot-module-replacement.mdx","name":"hot-module-replacement.mdx","size":4931,"type":"file","extension":".mdx","url":"/concepts/hot-module-replacement/","anchors":[{"title":"How It Works","id":"how-it-works","level":2},{"title":"In the Application","id":"in-the-application","level":3},{"title":"In the Compiler","id":"in-the-compiler","level":3},{"title":"In a Module","id":"in-a-module","level":3},{"title":"In the Runtime","id":"in-the-runtime","level":3},{"title":"Get Started","id":"get-started","level":2}],"title":"Hot Module Replacement","sort":12,"contributors":["kryptokinght","SpaceK33z","sokra","GRardB","rouzbeh84","skipjack"]},{"path":"src/content/concepts/why-webpack.mdx","name":"why-webpack.mdx","size":4124,"type":"file","extension":".mdx","url":"/concepts/why-webpack/","anchors":[{"title":"IIFEs - Immediately invoked function expressions","id":"iifes---immediately-invoked-function-expressions","level":2},{"title":"Birth of JavaScript Modules happened thanks to Node.js","id":"birth-of-javascript-modules-happened-thanks-to-nodejs","level":2},{"title":"npm + Node.js + modules – mass distribution","id":"npm--nodejs--modules--mass-distribution","level":2},{"title":"ESM - ECMAScript Modules","id":"esm---ecmascript-modules","level":2},{"title":"Automatic Dependency Collection","id":"automatic-dependency-collection","level":2},{"title":"Wouldn\'t it be nice…","id":"wouldnt-it-be-nice","level":2}],"title":"Why webpack","sort":13,"contributors":["debs-obrien","montogeek","jeremenichelli","EugeneHlushko"]},{"path":"src/content/concepts/under-the-hood.mdx","name":"under-the-hood.mdx","size":3980,"type":"file","extension":".mdx","url":"/concepts/under-the-hood/","anchors":[{"title":"The main parts","id":"the-main-parts","level":2},{"title":"Chunks","id":"chunks","level":2},{"title":"Output","id":"output","level":2}],"title":"Under The Hood","sort":14,"contributors":["smelukov","EugeneHlushko","chenxsan","amirsaeed671"]}],"size":69248,"type":"directory","url":"/concepts/"},{"path":"src/content/configuration","name":"configuration","children":[{"path":"src/content/configuration/index.mdx","name":"index.mdx","size":3489,"type":"file","extension":".mdx","url":"/configuration/","anchors":[{"title":"Use a different configuration file","id":"use-a-different-configuration-file","level":2},{"title":"Set up a new webpack project","id":"set-up-a-new-webpack-project","level":2}],"title":"Configuration","sort":1,"contributors":["sokra","skipjack","grgur","bondz","sricc","terinjokes","mattce","kbariotis","sterlingvix","jeremenichelli","dasarianudeep","lukasgeiter","EugeneHlushko","bigdawggi","anshumanv","textbook","coly010","chenxsan"]},{"path":"src/content/configuration/configuration-languages.mdx","name":"configuration-languages.mdx","size":5756,"type":"file","extension":".mdx","url":"/configuration/configuration-languages/","anchors":[{"title":"TypeScript","id":"typescript","level":2},{"title":"CoffeeScript","id":"coffeescript","level":2},{"title":"Babel and JSX","id":"babel-and-jsx","level":2}],"title":"Configuration Languages","sort":2,"contributors":["piouson","sokra","skipjack","tarang9211","simon04","peterblazejewicz","youta1119","byzyk","Nek-","liyiming22","daimalou","ChocolateLoverRaj","snitin315"]},{"path":"src/content/configuration/configuration-types.mdx","name":"configuration-types.mdx","size":3714,"type":"file","extension":".mdx","url":"/configuration/configuration-types/","anchors":[{"title":"Exporting a Function","id":"exporting-a-function","level":2},{"title":"Exporting a Promise","id":"exporting-a-promise","level":2},{"title":"Exporting multiple configurations","id":"exporting-multiple-configurations","level":2},{"title":"dependencies","id":"dependencies","level":3},{"title":"parallelism","id":"parallelism","level":3}],"title":"Configuration Types","sort":3,"contributors":["sokra","skipjack","kbariotis","simon04","fadysamirsadek","byzyk","EugeneHlushko","dhurlburtusa","anshumanv","thorn0"]},{"path":"src/content/configuration/entry-context.mdx","name":"entry-context.mdx","size":5075,"type":"file","extension":".mdx","url":"/configuration/entry-context/","anchors":[{"title":"context","id":"context","level":2},{"title":"entry","id":"entry","level":2},{"title":"Naming","id":"naming","level":3},{"title":"Entry descriptor","id":"entry-descriptor","level":3},{"title":"Output filename","id":"output-filename","level":3},{"title":"Dependencies","id":"dependencies","level":3},{"title":"Dynamic entry","id":"dynamic-entry","level":3}],"title":"Entry and Context","sort":4,"contributors":["sokra","skipjack","tarang9211","byzyk","madhavarshney","EugeneHlushko","smelukov","anshumanv","snitin315"]},{"path":"src/content/configuration/mode.mdx","name":"mode.mdx","size":2960,"type":"file","extension":".mdx","url":"/configuration/mode/","anchors":[{"title":"Usage","id":"usage","level":2},{"title":"Mode: development","id":"mode-development","level":3},{"title":"Mode: production","id":"mode-production","level":3},{"title":"Mode: none","id":"mode-none","level":3}],"title":"Mode","sort":5,"contributors":["EugeneHlushko","byzyk","mrichmond","Fental","snitin315","chenxsan"],"related":[{"title":"webpack default options (source code)","url":"https://github.com/webpack/webpack/blob/main/lib/config/defaults.js"}]},{"path":"src/content/configuration/output.mdx","name":"output.mdx","size":70419,"type":"file","extension":".mdx","url":"/configuration/output/","anchors":[{"title":"output.assetModuleFilename","id":"outputassetmodulefilename","level":2},{"title":"output.asyncChunks","id":"outputasyncchunks","level":2},{"title":"output.auxiliaryComment","id":"outputauxiliarycomment","level":2},{"title":"output.charset","id":"outputcharset","level":2},{"title":"output.chunkFilename","id":"outputchunkfilename","level":2},{"title":"output.chunkFormat","id":"outputchunkformat","level":2},{"title":"output.chunkLoadTimeout","id":"outputchunkloadtimeout","level":2},{"title":"output.chunkLoadingGlobal","id":"outputchunkloadingglobal","level":2},{"title":"output.chunkLoading","id":"outputchunkloading","level":2},{"title":"output.clean","id":"outputclean","level":2},{"title":"output.compareBeforeEmit","id":"outputcomparebeforeemit","level":2},{"title":"output.crossOriginLoading","id":"outputcrossoriginloading","level":2},{"title":"output.devtoolFallbackModuleFilenameTemplate","id":"outputdevtoolfallbackmodulefilenametemplate","level":2},{"title":"output.devtoolModuleFilenameTemplate","id":"outputdevtoolmodulefilenametemplate","level":2},{"title":"output.devtoolNamespace","id":"outputdevtoolnamespace","level":2},{"title":"output.enabledChunkLoadingTypes","id":"outputenabledchunkloadingtypes","level":2},{"title":"output.enabledLibraryTypes","id":"outputenabledlibrarytypes","level":2},{"title":"output.enabledWasmLoadingTypes","id":"outputenabledwasmloadingtypes","level":2},{"title":"output.environment","id":"outputenvironment","level":2},{"title":"output.filename","id":"outputfilename","level":2},{"title":"Template strings","id":"template-strings","level":3},{"title":"output.globalObject","id":"outputglobalobject","level":2},{"title":"output.hashDigest","id":"outputhashdigest","level":2},{"title":"output.hashDigestLength","id":"outputhashdigestlength","level":2},{"title":"output.hashFunction","id":"outputhashfunction","level":2},{"title":"output.hashSalt","id":"outputhashsalt","level":2},{"title":"output.hotUpdateChunkFilename","id":"outputhotupdatechunkfilename","level":2},{"title":"output.hotUpdateGlobal","id":"outputhotupdateglobal","level":2},{"title":"output.hotUpdateMainFilename","id":"outputhotupdatemainfilename","level":2},{"title":"output.iife","id":"outputiife","level":2},{"title":"output.ignoreBrowserWarnings","id":"outputignorebrowserwarnings","level":2},{"title":"output.importFunctionName","id":"outputimportfunctionname","level":2},{"title":"output.library","id":"outputlibrary","level":2},{"title":"output.library.amdContainer","id":"outputlibraryamdcontainer","level":3},{"title":"output.library.name","id":"outputlibraryname","level":3},{"title":"output.library.type","id":"outputlibrarytype","level":3},{"title":"output.library.export","id":"outputlibraryexport","level":3},{"title":"output.library.auxiliaryComment","id":"outputlibraryauxiliarycomment","level":3},{"title":"output.library.umdNamedDefine","id":"outputlibraryumdnameddefine","level":3},{"title":"output.libraryExport","id":"outputlibraryexport-1","level":2},{"title":"output.libraryTarget","id":"outputlibrarytarget","level":2},{"title":"Expose a Variable","id":"expose-a-variable-1","level":3},{"title":"Expose Via Object Assignment","id":"expose-via-object-assignment-1","level":3},{"title":"Module Definition Systems","id":"module-definition-systems-1","level":3},{"title":"Other Targets","id":"other-targets","level":3},{"title":"output.module","id":"outputmodule","level":2},{"title":"output.path","id":"outputpath","level":2},{"title":"output.pathinfo","id":"outputpathinfo","level":2},{"title":"output.publicPath","id":"outputpublicpath","level":2},{"title":"output.scriptType","id":"outputscripttype","level":2},{"title":"output.sourceMapFilename","id":"outputsourcemapfilename","level":2},{"title":"output.sourcePrefix","id":"outputsourceprefix","level":2},{"title":"output.strictModuleErrorHandling","id":"outputstrictmoduleerrorhandling","level":2},{"title":"output.strictModuleExceptionHandling","id":"outputstrictmoduleexceptionhandling","level":2},{"title":"output.trustedTypes","id":"outputtrustedtypes","level":2},{"title":"output.trustedTypes.onPolicyCreationFailure","id":"outputtrustedtypesonpolicycreationfailure","level":3},{"title":"output.umdNamedDefine","id":"outputumdnameddefine","level":2},{"title":"output.uniqueName","id":"outputuniquename","level":2},{"title":"output.wasmLoading","id":"outputwasmloading","level":2},{"title":"output.workerChunkLoading","id":"outputworkerchunkloading","level":2},{"title":"output.workerPublicPath","id":"outputworkerpublicpath","level":2}],"title":"Output","sort":6,"contributors":["sokra","skipjack","tomasAlabes","mattce","irth","fvgs","dhurlburtusa","MagicDuck","fadysamirsadek","byzyk","madhavarshney","harshwardhansingh","eemeli","EugeneHlushko","g-plane","smelukov","Neob91","anikethsaha","jamesgeorge007","hiroppy","chenxsan","snitin315","QC-L","anshumanv","mrzalyaul","JakobJingleheimer","long76"]},{"path":"src/content/configuration/module.mdx","name":"module.mdx","size":36956,"type":"file","extension":".mdx","url":"/configuration/module/","anchors":[{"title":"module.defaultRules","id":"moduledefaultrules","level":2},{"title":"module.generator","id":"modulegenerator","level":2},{"title":"module.parser","id":"moduleparser","level":2},{"title":"module.parser.javascript","id":"moduleparserjavascript","level":3},{"title":"module.noParse","id":"modulenoparse","level":2},{"title":"module.unsafeCache","id":"moduleunsafecache","level":2},{"title":"module.rules","id":"modulerules","level":2},{"title":"Rule","id":"rule","level":2},{"title":"Rule Conditions","id":"rule-conditions","level":3},{"title":"Rule results","id":"rule-results","level":3},{"title":"Nested rules","id":"nested-rules","level":2},{"title":"Rule.enforce","id":"ruleenforce","level":2},{"title":"Rule.exclude","id":"ruleexclude","level":2},{"title":"Rule.include","id":"ruleinclude","level":2},{"title":"Rule.issuer","id":"ruleissuer","level":2},{"title":"Rule.issuerLayer","id":"ruleissuerlayer","level":2},{"title":"Rule.layer","id":"rulelayer","level":2},{"title":"Rule.loader","id":"ruleloader","level":2},{"title":"Rule.loaders","id":"ruleloaders","level":2},{"title":"Rule.mimetype","id":"rulemimetype","level":2},{"title":"Rule.oneOf","id":"ruleoneof","level":2},{"title":"Rule.options / Rule.query","id":"ruleoptions--rulequery","level":2},{"title":"Rule.parser","id":"ruleparser","level":2},{"title":"Rule.parser.dataUrlCondition","id":"ruleparserdataurlcondition","level":2},{"title":"Rule.generator","id":"rulegenerator","level":2},{"title":"Rule.generator.dataUrl","id":"rulegeneratordataurl","level":3},{"title":"Rule.generator.emit","id":"rulegeneratoremit","level":3},{"title":"Rule.generator.filename","id":"rulegeneratorfilename","level":3},{"title":"Rule.generator.publicPath","id":"rulegeneratorpublicpath","level":3},{"title":"Rule.generator.outputPath","id":"rulegeneratoroutputpath","level":3},{"title":"Rule.resource","id":"ruleresource","level":2},{"title":"Rule.resourceQuery","id":"ruleresourcequery","level":2},{"title":"Rule.parser.parse","id":"ruleparserparse","level":2},{"title":"Rule.rules","id":"rulerules","level":2},{"title":"Rule.scheme","id":"rulescheme","level":2},{"title":"Rule.sideEffects","id":"rulesideeffects","level":2},{"title":"Rule.test","id":"ruletest","level":2},{"title":"Rule.type","id":"ruletype","level":2},{"title":"css/auto","id":"cssauto","level":3},{"title":"Rule.use","id":"ruleuse","level":2},{"title":"Rule.resolve","id":"ruleresolve","level":2},{"title":"resolve.fullySpecified","id":"resolvefullyspecified","level":3},{"title":"Condition","id":"condition","level":2},{"title":"UseEntry","id":"useentry","level":2},{"title":"Module Contexts","id":"module-contexts","level":2}],"title":"Module","sort":7,"contributors":["sokra","skipjack","jouni-kantola","jhnns","dylanonelson","byzyk","pnevares","fadysamirsadek","nerdkid93","EugeneHlushko","superburrito","lukasgeiter","skovy","smelukov","opl-","Mistyyyy","anshumanv","chenxsan","snitin315","vabushkevich"]},{"path":"src/content/configuration/resolve.mdx","name":"resolve.mdx","size":17803,"type":"file","extension":".mdx","url":"/configuration/resolve/","anchors":[{"title":"resolve","id":"resolve","level":2},{"title":"resolve.alias","id":"resolvealias","level":3},{"title":"resolve.aliasFields","id":"resolvealiasfields","level":3},{"title":"resolve.cacheWithContext","id":"resolvecachewithcontext","level":3},{"title":"resolve.conditionNames","id":"resolveconditionnames","level":3},{"title":"resolve.descriptionFiles","id":"resolvedescriptionfiles","level":3},{"title":"resolve.enforceExtension","id":"resolveenforceextension","level":3},{"title":"resolve.extensionAlias","id":"resolveextensionalias","level":3},{"title":"resolve.extensions","id":"resolveextensions","level":3},{"title":"resolve.fallback","id":"resolvefallback","level":3},{"title":"resolve.mainFields","id":"resolvemainfields","level":3},{"title":"resolve.mainFiles","id":"resolvemainfiles","level":3},{"title":"resolve.exportsFields","id":"resolveexportsfields","level":3},{"title":"resolve.modules","id":"resolvemodules","level":3},{"title":"resolve.unsafeCache","id":"resolveunsafecache","level":3},{"title":"resolve.useSyncFileSystemCalls","id":"resolveusesyncfilesystemcalls","level":3},{"title":"resolve.plugins","id":"resolveplugins","level":3},{"title":"resolve.preferRelative","id":"resolvepreferrelative","level":3},{"title":"resolve.preferAbsolute","id":"resolvepreferabsolute","level":3},{"title":"resolve.symlinks","id":"resolvesymlinks","level":3},{"title":"resolve.cachePredicate","id":"resolvecachepredicate","level":3},{"title":"resolve.restrictions","id":"resolverestrictions","level":3},{"title":"resolve.roots","id":"resolveroots","level":3},{"title":"resolve.importsFields","id":"resolveimportsfields","level":3},{"title":"resolve.byDependency","id":"resolvebydependency","level":3},{"title":"resolveLoader","id":"resolveloader","level":2}],"title":"Resolve","sort":8,"contributors":["sokra","skipjack","SpaceK33z","pksjce","sebastiandeutsch","tbroadley","byzyk","numb86","jgravois","EugeneHlushko","Aghassi","myshov","anikethsaha","chenxsan","jamesgeorge007","snitin315"]},{"path":"src/content/configuration/optimization.mdx","name":"optimization.mdx","size":17660,"type":"file","extension":".mdx","url":"/configuration/optimization/","anchors":[{"title":"optimization.chunkIds","id":"optimizationchunkids","level":2},{"title":"optimization.concatenateModules","id":"optimizationconcatenatemodules","level":2},{"title":"optimization.emitOnErrors","id":"optimizationemitonerrors","level":2},{"title":"optimization.flagIncludedChunks","id":"optimizationflagincludedchunks","level":2},{"title":"optimization.innerGraph","id":"optimizationinnergraph","level":2},{"title":"optimization.mangleExports","id":"optimizationmangleexports","level":2},{"title":"optimization.mangleWasmImports","id":"optimizationmanglewasmimports","level":2},{"title":"optimization.mergeDuplicateChunks","id":"optimizationmergeduplicatechunks","level":2},{"title":"optimization.minimize","id":"optimizationminimize","level":2},{"title":"optimization.minimizer","id":"optimizationminimizer","level":2},{"title":"optimization.moduleIds","id":"optimizationmoduleids","level":2},{"title":"optimization.nodeEnv","id":"optimizationnodeenv","level":2},{"title":"optimization.portableRecords","id":"optimizationportablerecords","level":2},{"title":"optimization.providedExports","id":"optimizationprovidedexports","level":2},{"title":"optimization.realContentHash","id":"optimizationrealcontenthash","level":2},{"title":"optimization.removeAvailableModules","id":"optimizationremoveavailablemodules","level":2},{"title":"optimization.removeEmptyChunks","id":"optimizationremoveemptychunks","level":2},{"title":"optimization.runtimeChunk","id":"optimizationruntimechunk","level":2},{"title":"optimization.sideEffects","id":"optimizationsideeffects","level":2},{"title":"optimization.splitChunks","id":"optimizationsplitchunks","level":2},{"title":"optimization.usedExports","id":"optimizationusedexports","level":2}],"title":"Optimization","sort":9,"contributors":["EugeneHlushko","jeremenichelli","simon04","byzyk","madhavarshney","dhurlburtusa","jamesgeorge007","anikethsaha","snitin315","pixel-ray","chenxsan","Roberto14"],"related":[{"title":"webpack 4: Code Splitting, chunk graph and the splitChunks optimization","url":"https://medium.com/webpack/webpack-4-code-splitting-chunk-graph-and-the-splitchunks-optimization-be739a861366"}]},{"path":"src/content/configuration/plugins.mdx","name":"plugins.mdx","size":1847,"type":"file","extension":".mdx","url":"/configuration/plugins/","anchors":[{"title":"plugins","id":"plugins","level":2}],"title":"Plugins","sort":10,"contributors":["sokra","skipjack","yatharthk","byzyk","EugeneHlushko","snitin315"]},{"path":"src/content/configuration/dev-server.mdx","name":"dev-server.mdx","size":42513,"type":"file","extension":".mdx","url":"/configuration/dev-server/","anchors":[{"title":"devServer","id":"devserver","level":2},{"title":"Usage via CLI","id":"usage-via-cli","level":3},{"title":"Usage via API","id":"usage-via-api","level":3},{"title":"devServer.allowedHosts","id":"devserverallowedhosts","level":2},{"title":"devServer.bonjour","id":"devserverbonjour","level":2},{"title":"devServer.client","id":"devserverclient","level":2},{"title":"logging","id":"logging","level":3},{"title":"overlay","id":"overlay","level":3},{"title":"progress","id":"progress","level":3},{"title":"reconnect","id":"reconnect","level":3},{"title":"webSocketTransport","id":"websockettransport","level":3},{"title":"webSocketURL","id":"websocketurl","level":3},{"title":"devServer.compress","id":"devservercompress","level":2},{"title":"devServer.devMiddleware","id":"devserverdevmiddleware","level":2},{"title":"devServer.http2","id":"devserverhttp2","level":2},{"title":"devServer.https","id":"devserverhttps","level":2},{"title":"devServer.headers","id":"devserverheaders","level":2},{"title":"devServer.historyApiFallback","id":"devserverhistoryapifallback","level":2},{"title":"devServer.host","id":"devserverhost","level":2},{"title":"local-ip","id":"local-ip","level":3},{"title":"local-ipv4","id":"local-ipv4","level":3},{"title":"local-ipv6","id":"local-ipv6","level":3},{"title":"devServer.hot","id":"devserverhot","level":2},{"title":"devServer.ipc","id":"devserveripc","level":2},{"title":"devServer.liveReload","id":"devserverlivereload","level":2},{"title":"devServer.magicHtml","id":"devservermagichtml","level":2},{"title":"devServer.onAfterSetupMiddleware","id":"devserveronaftersetupmiddleware","level":2},{"title":"devServer.onBeforeSetupMiddleware","id":"devserveronbeforesetupmiddleware","level":2},{"title":"devserver.onListening","id":"devserveronlistening","level":2},{"title":"devServer.open","id":"devserveropen","level":2},{"title":"devServer.port","id":"devserverport","level":2},{"title":"devServer.proxy","id":"devserverproxy","level":2},{"title":"devServer.server","id":"devserverserver","level":2},{"title":"devServer.setupExitSignals","id":"devserversetupexitsignals","level":2},{"title":"devServer.setupMiddlewares","id":"devserversetupmiddlewares","level":2},{"title":"devServer.static","id":"devserverstatic","level":2},{"title":"directory","id":"directory","level":3},{"title":"staticOptions","id":"staticoptions","level":3},{"title":"publicPath","id":"publicpath","level":3},{"title":"serveIndex","id":"serveindex","level":3},{"title":"watch","id":"watch","level":3},{"title":"devServer.watchFiles","id":"devserverwatchfiles","level":2},{"title":"devServer.webSocketServer","id":"devserverwebsocketserver","level":2}],"title":"DevServer","sort":11,"contributors":["sokra","skipjack","spacek33z","charlespwd","orteth01","byzyk","EugeneHlushko","Yiidiir","Loonride","dmohns","EslamHiko","digitaljohn","bhavya9107","wizardofhogwarts","jamesgeorge007","g100g","anikethsaha","snitin315","Biki-das","SaulSilver","malcolm-kee"]},{"path":"src/content/configuration/cache.mdx","name":"cache.mdx","size":11908,"type":"file","extension":".mdx","url":"/configuration/cache/","anchors":[{"title":"cache","id":"cache","level":2},{"title":"cache.allowCollectingMemory","id":"cacheallowcollectingmemory","level":3},{"title":"cache.buildDependencies","id":"cachebuilddependencies","level":3},{"title":"cache.cacheDirectory","id":"cachecachedirectory","level":3},{"title":"cache.cacheLocation","id":"cachecachelocation","level":3},{"title":"cache.cacheUnaffected","id":"cachecacheunaffected","level":3},{"title":"cache.compression","id":"cachecompression","level":3},{"title":"cache.hashAlgorithm","id":"cachehashalgorithm","level":3},{"title":"cache.idleTimeout","id":"cacheidletimeout","level":3},{"title":"cache.idleTimeoutAfterLargeChanges","id":"cacheidletimeoutafterlargechanges","level":3},{"title":"cache.idleTimeoutForInitialStore","id":"cacheidletimeoutforinitialstore","level":3},{"title":"cache.managedPaths","id":"cachemanagedpaths","level":3},{"title":"cache.maxAge","id":"cachemaxage","level":3},{"title":"cache.maxGenerations","id":"cachemaxgenerations","level":3},{"title":"cache.maxMemoryGenerations","id":"cachemaxmemorygenerations","level":3},{"title":"cache.memoryCacheUnaffected","id":"cachememorycacheunaffected","level":3},{"title":"cache.name","id":"cachename","level":3},{"title":"cache.profile","id":"cacheprofile","level":3},{"title":"cache.readonly","id":"cachereadonly","level":3},{"title":"cache.store","id":"cachestore","level":3},{"title":"cache.type","id":"cachetype","level":3},{"title":"cache.version","id":"cacheversion","level":3},{"title":"Setup cache in CI/CD system","id":"setup-cache-in-cicd-system","level":2},{"title":"GitLab CI/CD","id":"gitlab-cicd","level":3},{"title":"Github actions","id":"github-actions","level":3}],"title":"Cache","sort":12,"contributors":["snitin315","chenxsan"]},{"path":"src/content/configuration/devtool.mdx","name":"devtool.mdx","size":17292,"type":"file","extension":".mdx","url":"/configuration/devtool/","anchors":[{"title":"devtool","id":"devtool","level":2},{"title":"Qualities","id":"qualities","level":3},{"title":"Development","id":"development","level":3},{"title":"Special cases","id":"special-cases","level":3},{"title":"Production","id":"production","level":3}],"title":"Devtool","sort":12,"contributors":["sokra","skipjack","SpaceK33z","lricoy","madhavarshney","wizardofhogwarts","anikethsaha","snitin315"],"related":[{"title":"Enabling Source Maps","url":"https://survivejs.com/webpack/developing-with-webpack/enabling-sourcemaps/"},{"title":"webpack\'s Devtool Source Map","url":"http://cheng.logdown.com/posts/2016/03/25/679045"}]},{"path":"src/content/configuration/extending-configurations.mdx","name":"extending-configurations.mdx","size":3419,"type":"file","extension":".mdx","url":"/configuration/extending-configurations/","anchors":[{"title":"extends","id":"extends","level":2},{"title":"Extending multiple configurations","id":"extending-multiple-configurations","level":2},{"title":"Overridding Configurations","id":"overridding-configurations","level":2},{"title":"Loading configuration from external packages","id":"loading-configuration-from-external-packages","level":2}],"title":"Extends","sort":12,"contributors":["burhanuday"]},{"path":"src/content/configuration/target.mdx","name":"target.mdx","size":7857,"type":"file","extension":".mdx","url":"/configuration/target/","anchors":[{"title":"target","id":"target","level":2},{"title":"string","id":"string","level":3},{"title":"[string]","id":"string-1","level":3},{"title":"false","id":"false","level":3}],"title":"Target","sort":13,"contributors":["juangl","sokra","skipjack","SpaceK33z","pastelsky","tbroadley","byzyk","EugeneHlushko","smelukov","chenxsan"]},{"path":"src/content/configuration/watch.mdx","name":"watch.mdx","size":6463,"type":"file","extension":".mdx","url":"/configuration/watch/","anchors":[{"title":"watch","id":"watch","level":2},{"title":"watchOptions","id":"watchoptions","level":2},{"title":"watchOptions.aggregateTimeout","id":"watchoptionsaggregatetimeout","level":3},{"title":"watchOptions.ignored","id":"watchoptionsignored","level":3},{"title":"watchOptions.poll","id":"watchoptionspoll","level":3},{"title":"watchOptions.followSymlinks","id":"watchoptionsfollowsymlinks","level":3},{"title":"watchOptions.stdin","id":"watchoptionsstdin","level":3},{"title":"Troubleshooting","id":"troubleshooting","level":2},{"title":"Changes Seen But Not Processed","id":"changes-seen-but-not-processed","level":3},{"title":"Not Enough Watchers","id":"not-enough-watchers","level":3},{"title":"macOS fsevents Bug","id":"macos-fsevents-bug","level":3},{"title":"Windows Paths","id":"windows-paths","level":3},{"title":"Vim","id":"vim","level":3},{"title":"Saving in WebStorm","id":"saving-in-webstorm","level":3}],"title":"Watch and WatchOptions","sort":14,"contributors":["sokra","skipjack","SpaceK33z","EugeneHlushko","byzyk","spicalous","Neob91","Loonride","snitin315","chenxsan"]},{"path":"src/content/configuration/externals.mdx","name":"externals.mdx","size":21244,"type":"file","extension":".mdx","url":"/configuration/externals/","anchors":[{"title":"externals","id":"externals","level":2},{"title":"string","id":"string","level":3},{"title":"[string]","id":"string-1","level":3},{"title":"object","id":"object","level":3},{"title":"function","id":"function","level":3},{"title":"RegExp","id":"regexp","level":3},{"title":"Combining syntaxes","id":"combining-syntaxes","level":3},{"title":"byLayer","id":"bylayer","level":3},{"title":"externalsType","id":"externalstype","level":2},{"title":"externalsType.commonjs","id":"externalstypecommonjs","level":3},{"title":"externalsType.global","id":"externalstypeglobal","level":3},{"title":"externalsType.module","id":"externalstypemodule","level":3},{"title":"externalsType.node-commonjs","id":"externalstypenode-commonjs","level":3},{"title":"externalsType.promise","id":"externalstypepromise","level":3},{"title":"externalsType.self","id":"externalstypeself","level":3},{"title":"externalsType.script","id":"externalstypescript","level":3},{"title":"externalsType.this","id":"externalstypethis","level":3},{"title":"externalsType.var","id":"externalstypevar","level":3},{"title":"externalsType.window","id":"externalstypewindow","level":3},{"title":"externalsPresets","id":"externalspresets","level":2}],"title":"Externals","sort":15,"contributors":["sokra","skipjack","pksjce","fadysamirsadek","byzyk","zefman","Mistyyyy","jamesgeorge007","tanhauhau","snitin315","beejunk","EugeneHlushko","chenxsan","pranshuchittora","kinetifex","anshumanv","SaulSilver"]},{"path":"src/content/configuration/performance.mdx","name":"performance.mdx","size":2639,"type":"file","extension":".mdx","url":"/configuration/performance/","anchors":[{"title":"performance","id":"performance","level":2},{"title":"performance.assetFilter","id":"performanceassetfilter","level":3},{"title":"performance.hints","id":"performancehints","level":3},{"title":"performance.maxAssetSize","id":"performancemaxassetsize","level":3},{"title":"performance.maxEntrypointSize","id":"performancemaxentrypointsize","level":3}],"title":"Performance","sort":16,"contributors":["thelarkinn","tbroadley","byzyk","madhavarshney","EugeneHlushko"]},{"path":"src/content/configuration/node.mdx","name":"node.mdx","size":2484,"type":"file","extension":".mdx","url":"/configuration/node/","anchors":[{"title":"node","id":"node","level":2},{"title":"node.global","id":"nodeglobal","level":2},{"title":"node.__filename","id":"node__filename","level":2},{"title":"node.__dirname","id":"node__dirname","level":2}],"title":"Node","sort":17,"contributors":["sokra","skipjack","oneforwonder","Rob--W","byzyk","EugeneHlushko","anikethsaha","chenxsan"]},{"path":"src/content/configuration/stats.mdx","name":"stats.mdx","size":23173,"type":"file","extension":".mdx","url":"/configuration/stats/","anchors":[{"title":"Stats Presets","id":"stats-presets","level":2},{"title":"Stats Options","id":"stats-options","level":2},{"title":"stats.all","id":"statsall","level":3},{"title":"stats.assets","id":"statsassets","level":3},{"title":"stats.assetsSort","id":"statsassetssort","level":3},{"title":"stats.builtAt","id":"statsbuiltat","level":3},{"title":"stats.moduleAssets","id":"statsmoduleassets","level":3},{"title":"stats.assetsSpace","id":"statsassetsspace","level":3},{"title":"stats.modulesSpace","id":"statsmodulesspace","level":3},{"title":"stats.chunkModulesSpace","id":"statschunkmodulesspace","level":3},{"title":"stats.nestedModules","id":"statsnestedmodules","level":3},{"title":"stats.nestedModulesSpace","id":"statsnestedmodulesspace","level":3},{"title":"stats.cached","id":"statscached","level":3},{"title":"stats.cachedModules","id":"statscachedmodules","level":3},{"title":"stats.runtimeModules","id":"statsruntimemodules","level":3},{"title":"stats.dependentModules","id":"statsdependentmodules","level":3},{"title":"stats.groupAssetsByChunk","id":"statsgroupassetsbychunk","level":3},{"title":"stats.groupAssetsByEmitStatus","id":"statsgroupassetsbyemitstatus","level":3},{"title":"stats.groupAssetsByExtension","id":"statsgroupassetsbyextension","level":3},{"title":"stats.groupAssetsByInfo","id":"statsgroupassetsbyinfo","level":3},{"title":"stats.groupAssetsByPath","id":"statsgroupassetsbypath","level":3},{"title":"stats.groupModulesByAttributes","id":"statsgroupmodulesbyattributes","level":3},{"title":"stats.groupModulesByCacheStatus","id":"statsgroupmodulesbycachestatus","level":3},{"title":"stats.groupModulesByExtension","id":"statsgroupmodulesbyextension","level":3},{"title":"stats.groupModulesByLayer","id":"statsgroupmodulesbylayer","level":3},{"title":"stats.groupModulesByPath","id":"statsgroupmodulesbypath","level":3},{"title":"stats.groupModulesByType","id":"statsgroupmodulesbytype","level":3},{"title":"stats.groupReasonsByOrigin","id":"statsgroupreasonsbyorigin","level":3},{"title":"stats.cachedAssets","id":"statscachedassets","level":3},{"title":"stats.children","id":"statschildren","level":3},{"title":"stats.chunks","id":"statschunks","level":3},{"title":"stats.chunkGroups","id":"statschunkgroups","level":3},{"title":"stats.chunkModules","id":"statschunkmodules","level":3},{"title":"stats.chunkOrigins","id":"statschunkorigins","level":3},{"title":"stats.chunksSort","id":"statschunkssort","level":3},{"title":"stats.context","id":"statscontext","level":3},{"title":"stats.colors","id":"statscolors","level":3},{"title":"stats.depth","id":"statsdepth","level":3},{"title":"stats.entrypoints","id":"statsentrypoints","level":3},{"title":"stats.env","id":"statsenv","level":3},{"title":"stats.orphanModules","id":"statsorphanmodules","level":3},{"title":"stats.errors","id":"statserrors","level":3},{"title":"stats.errorDetails","id":"statserrordetails","level":3},{"title":"stats.errorStack","id":"statserrorstack","level":3},{"title":"stats.errorsSpace","id":"statserrorsspace","level":3},{"title":"stats.excludeAssets","id":"statsexcludeassets","level":3},{"title":"stats.excludeModules","id":"statsexcludemodules","level":3},{"title":"stats.exclude","id":"statsexclude","level":3},{"title":"stats.hash","id":"statshash","level":3},{"title":"stats.logging","id":"statslogging","level":3},{"title":"stats.loggingDebug","id":"statsloggingdebug","level":3},{"title":"stats.loggingTrace","id":"statsloggingtrace","level":3},{"title":"stats.modules","id":"statsmodules","level":3},{"title":"stats.modulesSort","id":"statsmodulessort","level":3},{"title":"stats.moduleTrace","id":"statsmoduletrace","level":3},{"title":"stats.optimizationBailout","id":"statsoptimizationbailout","level":3},{"title":"stats.outputPath","id":"statsoutputpath","level":3},{"title":"stats.performance","id":"statsperformance","level":3},{"title":"stats.preset","id":"statspreset","level":3},{"title":"stats.providedExports","id":"statsprovidedexports","level":3},{"title":"stats.errorsCount","id":"statserrorscount","level":3},{"title":"stats.warningsCount","id":"statswarningscount","level":3},{"title":"stats.publicPath","id":"statspublicpath","level":3},{"title":"stats.reasons","id":"statsreasons","level":3},{"title":"stats.reasonsSpace","id":"statsreasonsspace","level":3},{"title":"stats.relatedAssets","id":"statsrelatedassets","level":3},{"title":"stats.source","id":"statssource","level":3},{"title":"stats.timings","id":"statstimings","level":3},{"title":"stats.ids","id":"statsids","level":3},{"title":"stats.usedExports","id":"statsusedexports","level":3},{"title":"stats.version","id":"statsversion","level":3},{"title":"stats.chunkGroupAuxiliary","id":"statschunkgroupauxiliary","level":3},{"title":"stats.chunkGroupChildren","id":"statschunkgroupchildren","level":3},{"title":"stats.chunkGroupMaxAssets","id":"statschunkgroupmaxassets","level":3},{"title":"stats.warnings","id":"statswarnings","level":3},{"title":"stats.warningsSpace","id":"statswarningsspace","level":3},{"title":"stats.warningsFilter","id":"statswarningsfilter","level":3},{"title":"stats.chunkRelations","id":"statschunkrelations","level":3},{"title":"Sorting fields","id":"sorting-fields","level":3},{"title":"Extending stats behaviours","id":"extending-stats-behaviours","level":3}],"title":"Stats","sort":18,"contributors":["SpaceK33z","sallar","jungomi","ldrick","jasonblanchard","byzyk","renjithspace","Raiondesu","EugeneHlushko","grgur","anshumanv","pixel-ray","snitin315","u01jmg3","grrizzly"]},{"path":"src/content/configuration/experiments.mdx","name":"experiments.mdx","size":9572,"type":"file","extension":".mdx","url":"/configuration/experiments/","anchors":[{"title":"experiments","id":"experiments","level":2},{"title":"experiments.backCompat","id":"experimentsbackcompat","level":3},{"title":"experiments.buildHttp","id":"experimentsbuildhttp","level":3},{"title":"experiments.css","id":"experimentscss","level":3},{"title":"experiments.cacheUnaffected","id":"experimentscacheunaffected","level":3},{"title":"experiments.futureDefaults","id":"experimentsfuturedefaults","level":3},{"title":"experiments.lazyCompilation","id":"experimentslazycompilation","level":3},{"title":"experiments.outputModule","id":"experimentsoutputmodule","level":3},{"title":"experiments.topLevelAwait","id":"experimentstoplevelawait","level":3}],"title":"Experiments","sort":19,"contributors":["EugeneHlushko","wizardofhogwarts","chenxsan","anshumanv","snitin315","burhanuday"]},{"path":"src/content/configuration/other-options.mdx","name":"other-options.mdx","size":13286,"type":"file","extension":".mdx","url":"/configuration/other-options/","anchors":[{"title":"amd","id":"amd","level":2},{"title":"bail","id":"bail","level":2},{"title":"dependencies","id":"dependencies","level":2},{"title":"ignoreWarnings","id":"ignorewarnings","level":2},{"title":"infrastructureLogging","id":"infrastructurelogging","level":2},{"title":"appendOnly","id":"appendonly","level":3},{"title":"colors","id":"colors","level":3},{"title":"console","id":"console","level":3},{"title":"debug","id":"debug","level":3},{"title":"level","id":"level","level":3},{"title":"stream","id":"stream","level":3},{"title":"loader","id":"loader","level":2},{"title":"name","id":"name","level":2},{"title":"parallelism","id":"parallelism","level":2},{"title":"profile","id":"profile","level":2},{"title":"recordsInputPath","id":"recordsinputpath","level":2},{"title":"recordsOutputPath","id":"recordsoutputpath","level":2},{"title":"recordsPath","id":"recordspath","level":2},{"title":"snapshot","id":"snapshot","level":2},{"title":"buildDependencies","id":"builddependencies","level":3},{"title":"immutablePaths","id":"immutablepaths","level":3},{"title":"managedPaths","id":"managedpaths","level":3},{"title":"module","id":"module","level":3},{"title":"resolve","id":"resolve","level":3},{"title":"resolveBuildDependencies","id":"resolvebuilddependencies","level":3}],"title":"Other Options","sort":20,"contributors":["sokra","skipjack","terinjokes","byzyk","liorgreenb","vansosnin","EugeneHlushko","skovy","rishabh3112","niravasher","Neob91","chenxsan","u01jmg3","jamesgeorge007","snitin315"],"related":[{"title":"Using Records","url":"https://survivejs.com/webpack/optimizing/separating-manifest/#using-records"}]}],"size":327529,"type":"directory","url":"/configuration/"},{"path":"src/content/contribute","name":"contribute","children":[{"path":"src/content/contribute/index.mdx","name":"index.mdx","size":4703,"type":"file","extension":".mdx","url":"/contribute/","anchors":[{"title":"Developers","id":"developers","level":2},{"title":"How Can I Help?","id":"how-can-i-help","level":3},{"title":"Encouraging Employers","id":"encouraging-employers","level":3},{"title":"Your Contributions","id":"your-contributions","level":3},{"title":"Executives","id":"executives","level":2},{"title":"Sponsorship","id":"sponsorship","level":3},{"title":"Anyone Else","id":"anyone-else","level":3},{"title":"Pull requests","id":"pull-requests","level":2}],"title":"Contribute","sort":-1,"contributors":["rouzbeh84","scottdj92","harrynewsome","dhedgecock","tbroadley","EugeneHlushko","dkdk225"]},{"path":"src/content/contribute/writers-guide.mdx","name":"writers-guide.mdx","size":6883,"type":"file","extension":".mdx","url":"/contribute/writers-guide/","anchors":[{"title":"Process","id":"process","level":2},{"title":"YAML Frontmatter","id":"yaml-frontmatter","level":2},{"title":"Article Structure","id":"article-structure","level":2},{"title":"Typesetting","id":"typesetting","level":2},{"title":"Formatting","id":"formatting","level":2},{"title":"Code","id":"code","level":3},{"title":"Lists","id":"lists","level":3},{"title":"Tables","id":"tables","level":3},{"title":"Configuration Properties","id":"configuration-properties","level":3},{"title":"Quotes","id":"quotes","level":3},{"title":"Assumptions and simplicity","id":"assumptions-and-simplicity","level":3},{"title":"Configuration defaults and types","id":"configuration-defaults-and-types","level":3},{"title":"Options shortlists and their typing","id":"options-shortlists-and-their-typing","level":3},{"title":"Adding links","id":"adding-links","level":3}],"title":"Writer\'s Guide","sort":1,"contributors":["pranshuchittora","EugeneHlushko"]},{"path":"src/content/contribute/writing-a-loader.mdx","name":"writing-a-loader.mdx","size":13545,"type":"file","extension":".mdx","url":"/contribute/writing-a-loader/","anchors":[{"title":"Setup","id":"setup","level":2},{"title":"Simple Usage","id":"simple-usage","level":2},{"title":"Complex Usage","id":"complex-usage","level":2},{"title":"Guidelines","id":"guidelines","level":2},{"title":"Simple","id":"simple","level":3},{"title":"Chaining","id":"chaining","level":3},{"title":"Modular","id":"modular","level":3},{"title":"Stateless","id":"stateless","level":3},{"title":"Loader Utilities","id":"loader-utilities","level":3},{"title":"Loader Dependencies","id":"loader-dependencies","level":3},{"title":"Module Dependencies","id":"module-dependencies","level":3},{"title":"Common Code","id":"common-code","level":3},{"title":"Absolute Paths","id":"absolute-paths","level":3},{"title":"Peer Dependencies","id":"peer-dependencies","level":3},{"title":"Testing","id":"testing","level":2}],"title":"Writing a Loader","sort":2,"contributors":["asulaiman","michael-ciniawsky","byzyk","anikethsaha","jamesgeorge007","chenxsan","dev-itsheng"]},{"path":"src/content/contribute/writing-a-plugin.mdx","name":"writing-a-plugin.mdx","size":13637,"type":"file","extension":".mdx","url":"/contribute/writing-a-plugin/","anchors":[{"title":"Creating a Plugin","id":"creating-a-plugin","level":2},{"title":"Basic plugin architecture","id":"basic-plugin-architecture","level":2},{"title":"Compiler and Compilation","id":"compiler-and-compilation","level":2},{"title":"Async event hooks","id":"async-event-hooks","level":2},{"title":"tapAsync","id":"tapasync","level":3},{"title":"Example","id":"example","level":2},{"title":"Different Plugin Shapes","id":"different-plugin-shapes","level":2},{"title":"Synchronous Hooks","id":"synchronous-hooks","level":3},{"title":"Asynchronous Hooks","id":"asynchronous-hooks","level":3},{"title":"Configuration defaults","id":"configuration-defaults","level":3}],"title":"Writing a Plugin","sort":3,"contributors":["slavafomin","tbroadley","nveenjain","iamakulov","byzyk","franjohn21","EugeneHlushko","snitin315","rahul3v","jamesgeorge007"]},{"path":"src/content/contribute/plugin-patterns.mdx","name":"plugin-patterns.mdx","size":4742,"type":"file","extension":".mdx","url":"/contribute/plugin-patterns/","anchors":[{"title":"Exploring assets, chunks, modules, and dependencies","id":"exploring-assets-chunks-modules-and-dependencies","level":2},{"title":"Monitoring the watch graph","id":"monitoring-the-watch-graph","level":3},{"title":"Changed chunks","id":"changed-chunks","level":2}],"title":"Plugin Patterns","sort":5,"contributors":["nveenjain","EugeneHlushko","benglynn"]},{"path":"src/content/contribute/release-process.mdx","name":"release-process.mdx","size":831,"type":"file","extension":".mdx","url":"/contribute/release-process/","anchors":[{"title":"Pull Requests","id":"pull-requests","level":2},{"title":"Releasing","id":"releasing","level":2}],"title":"Release Process","sort":6,"contributors":["d3viant0ne","sokra","byzyk","chenxsan"]},{"path":"src/content/contribute/debugging.mdx","name":"debugging.mdx","size":3576,"type":"file","extension":".mdx","url":"/contribute/debugging/","anchors":[{"title":"Stats","id":"stats","level":2},{"title":"DevTools","id":"devtools","level":2}],"title":"Debugging","sort":7,"contributors":["skipjack","tbroadley","madhavarshney","bhavya9107","akaustav"],"related":[{"title":"Learn and Debug webpack with Chrome DevTools!","url":"https://medium.com/webpack/webpack-bits-learn-and-debug-webpack-with-chrome-dev-tools-da1c5b19554"},{"title":"Debugging Guide | Node","url":"https://nodejs.org/en/docs/guides/debugging-getting-started/"},{"title":"Debugging Node.js with Chrome DevTools","url":"https://medium.com/@paul_irish/debugging-node-js-nightlies-with-chrome-devtools-7c4a1b95ae27"}]}],"size":47917,"type":"directory","url":"/contribute/"},{"path":"src/content/guides","name":"guides","children":[{"path":"src/content/guides/index.mdx","name":"index.mdx","size":924,"type":"file","extension":".mdx","url":"/guides/","anchors":[],"title":"Guides","sort":-1,"contributors":["skipjack","EugeneHlushko","benschac"]},{"path":"src/content/guides/getting-started.mdx","name":"getting-started.mdx","size":12838,"type":"file","extension":".mdx","url":"/guides/getting-started/","anchors":[{"title":"Basic Setup","id":"basic-setup","level":2},{"title":"Creating a Bundle","id":"creating-a-bundle","level":2},{"title":"Modules","id":"modules","level":2},{"title":"Using a Configuration","id":"using-a-configuration","level":2},{"title":"NPM Scripts","id":"npm-scripts","level":2},{"title":"Conclusion","id":"conclusion","level":2}],"title":"Getting Started","description":"Learn how to bundle a JavaScript application with webpack 5.","sort":1,"contributors":["bebraw","varunjayaraman","cntanglijun","chrisVillanueva","johnstew","simon04","aaronang","TheDutchCoder","sudarsangp","Vanguard90","chenxsan","EugeneHlushko","ATGardner","ayvarot","bjarki","ztomasze","Spiral90210","byzyk","wizardofhogwarts","myshov","anshumanv","d3lm","snitin315","Etheryen"]},{"path":"src/content/guides/asset-management.mdx","name":"asset-management.mdx","size":24303,"type":"file","extension":".mdx","url":"/guides/asset-management/","anchors":[{"title":"Setup","id":"setup","level":2},{"title":"Loading CSS","id":"loading-css","level":2},{"title":"Loading Images","id":"loading-images","level":2},{"title":"Loading Fonts","id":"loading-fonts","level":2},{"title":"Loading Data","id":"loading-data","level":2},{"title":"Customize parser of JSON modules","id":"customize-parser-of-json-modules","level":3},{"title":"Global Assets","id":"global-assets","level":2},{"title":"Wrapping up","id":"wrapping-up","level":2},{"title":"Next guide","id":"next-guide","level":2},{"title":"Further Reading","id":"further-reading","level":2}],"title":"Asset Management","sort":2,"contributors":["skipjack","michael-ciniawsky","TheDutchCoder","sudarsangp","chenxsan","EugeneHlushko","AnayaDesign","wizardofhogwarts","astonizer","snitin315"]},{"path":"src/content/guides/output-management.mdx","name":"output-management.mdx","size":7573,"type":"file","extension":".mdx","url":"/guides/output-management/","anchors":[{"title":"Preparation","id":"preparation","level":2},{"title":"Setting up HtmlWebpackPlugin","id":"setting-up-htmlwebpackplugin","level":2},{"title":"Cleaning up the /dist folder","id":"cleaning-up-the-dist-folder","level":2},{"title":"The Manifest","id":"the-manifest","level":2},{"title":"Conclusion","id":"conclusion","level":2}],"title":"Output Management","sort":3,"contributors":["skipjack","TheDutchCoder","sudarsangp","JGJP","EugeneHlushko","AnayaDesign","chenxsan","snitin315"]},{"path":"src/content/guides/development.mdx","name":"development.mdx","size":14559,"type":"file","extension":".mdx","url":"/guides/development/","anchors":[{"title":"Using source maps","id":"using-source-maps","level":2},{"title":"Choosing a Development Tool","id":"choosing-a-development-tool","level":2},{"title":"Using Watch Mode","id":"using-watch-mode","level":3},{"title":"Using webpack-dev-server","id":"using-webpack-dev-server","level":3},{"title":"Using webpack-dev-middleware","id":"using-webpack-dev-middleware","level":3},{"title":"Adjusting Your Text Editor","id":"adjusting-your-text-editor","level":2},{"title":"Conclusion","id":"conclusion","level":2}],"title":"Development","sort":4,"contributors":["SpaceK33z","rafde","fvgs","TheDutchCoder","WojciechKo","Calinou","GAumala","EugeneHlushko","byzyk","trivikr","aholzner","chenxsan","maxloh","snitin315","f3ndot"]},{"path":"src/content/guides/code-splitting.mdx","name":"code-splitting.mdx","size":18088,"type":"file","extension":".mdx","url":"/guides/code-splitting/","anchors":[{"title":"Entry Points","id":"entry-points","level":2},{"title":"Prevent Duplication","id":"prevent-duplication","level":2},{"title":"Entry dependencies","id":"entry-dependencies","level":3},{"title":"SplitChunksPlugin","id":"splitchunksplugin","level":3},{"title":"Dynamic Imports","id":"dynamic-imports","level":2},{"title":"Prefetching/Preloading modules","id":"prefetchingpreloading-modules","level":2},{"title":"Bundle Analysis","id":"bundle-analysis","level":2},{"title":"Next Steps","id":"next-steps","level":2}],"title":"Code Splitting","sort":5,"contributors":["pksjce","pastelsky","simon04","jonwheeler","johnstew","shinxi","tomtasche","levy9527","rahulcs","chrisVillanueva","rafde","bartushek","shaunwallace","skipjack","jakearchibald","TheDutchCoder","rouzbeh84","shaodahong","sudarsangp","kcolton","efreitasn","EugeneHlushko","Tiendo1011","byzyk","AnayaDesign","wizardofhogwarts","maximilianschmelzer","smelukov","chenxsan","Adarah","atesgoral","snitin315","artem-malko"],"related":[{"title":" in webpack","url":"https://medium.com/webpack/link-rel-prefetch-preload-in-webpack-51a52358f84c"},{"title":"Preload, Prefetch And Priorities in Chrome","url":"https://medium.com/reloading/preload-prefetch-and-priorities-in-chrome-776165961bbf"},{"title":"Preloading content with ","url":"https://developer.mozilla.org/en-US/docs/Web/HTML/Preloading_content"}]},{"path":"src/content/guides/caching.mdx","name":"caching.mdx","size":11422,"type":"file","extension":".mdx","url":"/guides/caching/","anchors":[{"title":"Output Filenames","id":"output-filenames","level":2},{"title":"Extracting Boilerplate","id":"extracting-boilerplate","level":2},{"title":"Module Identifiers","id":"module-identifiers","level":2},{"title":"Conclusion","id":"conclusion","level":2}],"title":"Caching","sort":6,"contributors":["okonet","jouni-kantola","skipjack","dannycjones","fadysamirsadek","afontcu","rosavage","saiprasad2595","EugeneHlushko","AnayaDesign","aholzner","snitin315"],"related":[{"title":"Issue 652","url":"https://github.com/webpack/webpack.js.org/issues/652"}]},{"path":"src/content/guides/author-libraries.mdx","name":"author-libraries.mdx","size":8163,"type":"file","extension":".mdx","url":"/guides/author-libraries/","anchors":[{"title":"Authoring a Library","id":"authoring-a-library","level":2},{"title":"Webpack Configuration","id":"webpack-configuration","level":2},{"title":"Expose the Library","id":"expose-the-library","level":2},{"title":"Externalize Lodash","id":"externalize-lodash","level":2},{"title":"External Limitations","id":"external-limitations","level":3},{"title":"Final Steps","id":"final-steps","level":2}],"title":"Authoring Libraries","sort":7,"contributors":["pksjce","johnstew","simon04","5angel","marioacc","byzyk","EugeneHlushko","AnayaDesign","chenxsan","wizardofhogwarts"]},{"path":"src/content/guides/environment-variables.mdx","name":"environment-variables.mdx","size":1845,"type":"file","extension":".mdx","url":"/guides/environment-variables/","anchors":[],"title":"Environment Variables","sort":8,"contributors":["simon04","grisanu","tbroadley","legalcodes","byzyk","jceipek","snitin315"]},{"path":"src/content/guides/build-performance.mdx","name":"build-performance.mdx","size":8685,"type":"file","extension":".mdx","url":"/guides/build-performance/","anchors":[{"title":"General","id":"general","level":2},{"title":"Stay Up to Date","id":"stay-up-to-date","level":3},{"title":"Loaders","id":"loaders","level":3},{"title":"Bootstrap","id":"bootstrap","level":3},{"title":"Resolving","id":"resolving","level":3},{"title":"Dlls","id":"dlls","level":3},{"title":"Smaller = Faster","id":"smaller--faster","level":3},{"title":"Worker Pool","id":"worker-pool","level":3},{"title":"Persistent cache","id":"persistent-cache","level":3},{"title":"Custom plugins/loaders","id":"custom-pluginsloaders","level":3},{"title":"Progress plugin","id":"progress-plugin","level":3},{"title":"Development","id":"development","level":2},{"title":"Incremental Builds","id":"incremental-builds","level":3},{"title":"Compile in Memory","id":"compile-in-memory","level":3},{"title":"stats.toJson speed","id":"statstojson-speed","level":3},{"title":"Devtool","id":"devtool","level":3},{"title":"Avoid Production Specific Tooling","id":"avoid-production-specific-tooling","level":3},{"title":"Minimal Entry Chunk","id":"minimal-entry-chunk","level":3},{"title":"Avoid Extra Optimization Steps","id":"avoid-extra-optimization-steps","level":3},{"title":"Output Without Path Info","id":"output-without-path-info","level":3},{"title":"Node.js Versions 8.9.10-9.11.1","id":"nodejs-versions-8910-9111","level":3},{"title":"TypeScript Loader","id":"typescript-loader","level":3},{"title":"Production","id":"production","level":2},{"title":"Source Maps","id":"source-maps","level":3},{"title":"Specific Tooling Issues","id":"specific-tooling-issues","level":2},{"title":"Babel","id":"babel","level":3},{"title":"TypeScript","id":"typescript","level":3},{"title":"Sass","id":"sass","level":3}],"title":"Build Performance","sort":9,"contributors":["sokra","tbroadley","byzyk","madhavarshney","wizardofhogwarts","anikethsaha"]},{"path":"src/content/guides/csp.mdx","name":"csp.mdx","size":2291,"type":"file","extension":".mdx","url":"/guides/csp/","anchors":[{"title":"Examples","id":"examples","level":2},{"title":"Enabling CSP","id":"enabling-csp","level":2},{"title":"Trusted Types","id":"trusted-types","level":2}],"title":"Content Security Policies","sort":10,"contributors":["EugeneHlushko","probablyup","wizardofhogwarts","koto"],"related":[{"title":"Nonce purpose explained","url":"https://stackoverflow.com/questions/42922784/what-s-the-purpose-of-the-html-nonce-attribute-for-script-and-style-elements"},{"title":"On the Insecurity of Whitelists and the Future of Content Security Policy","url":"https://ai.google/research/pubs/pub45542"},{"title":"Locking Down Your Website Scripts with CSP, Hashes, Nonces and Report URI","url":"https://www.troyhunt.com/locking-down-your-website-scripts-with-csp-hashes-nonces-and-report-uri/"},{"title":"CSP on MDN","url":"https://developer.mozilla.org/en-US/docs/Web/HTTP/CSP"},{"title":"Trusted Types","url":"https://web.dev/trusted-types"}]},{"path":"src/content/guides/development-vagrant.mdx","name":"development-vagrant.mdx","size":3484,"type":"file","extension":".mdx","url":"/guides/development-vagrant/","anchors":[{"title":"Configuring the Project","id":"configuring-the-project","level":2},{"title":"Running the Server","id":"running-the-server","level":2},{"title":"Advanced Usage with nginx","id":"advanced-usage-with-nginx","level":2},{"title":"Conclusion","id":"conclusion","level":2}],"title":"Development - Vagrant","sort":11,"contributors":["SpaceK33z","chrisVillanueva","byzyk","wizardofhogwarts"]},{"path":"src/content/guides/dependency-management.mdx","name":"dependency-management.mdx","size":3159,"type":"file","extension":".mdx","url":"/guides/dependency-management/","anchors":[{"title":"require with expression","id":"require-with-expression","level":2},{"title":"require.context","id":"requirecontext","level":2},{"title":"context module API","id":"context-module-api","level":3}],"title":"Dependency Management","sort":12,"contributors":["ndelangen","chrisVillanueva","sokra","byzyk","AnayaDesign"]},{"path":"src/content/guides/installation.mdx","name":"installation.mdx","size":2799,"type":"file","extension":".mdx","url":"/guides/installation/","anchors":[{"title":"Prerequisites","id":"prerequisites","level":2},{"title":"Local Installation","id":"local-installation","level":2},{"title":"Global Installation","id":"global-installation","level":2},{"title":"Bleeding Edge","id":"bleeding-edge","level":2}],"title":"Installation","sort":13,"contributors":["pksjce","bebraw","simon04","EugeneHlushko","sibiraj-s","chenxsan"]},{"path":"src/content/guides/hot-module-replacement.mdx","name":"hot-module-replacement.mdx","size":12146,"type":"file","extension":".mdx","url":"/guides/hot-module-replacement/","anchors":[{"title":"Enabling HMR","id":"enabling-hmr","level":2},{"title":"Via the Node.js API","id":"via-the-nodejs-api","level":2},{"title":"Gotchas","id":"gotchas","level":2},{"title":"HMR with Stylesheets","id":"hmr-with-stylesheets","level":2},{"title":"Other Code and Frameworks","id":"other-code-and-frameworks","level":2}],"title":"Hot Module Replacement","sort":15,"contributors":["jmreidy","jhnns","sararubin","rohannair","joshsantos","drpicox","skipjack","sbaidon","gdi2290","bdwain","caryli","xgirma","EugeneHlushko","AnayaDesign","aviyacohen","dhruvdutt","wizardofhogwarts","aholzner","snitin315"],"related":[{"title":"Concepts - Hot Module Replacement","url":"/concepts/hot-module-replacement"},{"title":"API - Hot Module Replacement","url":"/api/hot-module-replacement"}]},{"path":"src/content/guides/tree-shaking.mdx","name":"tree-shaking.mdx","size":15044,"type":"file","extension":".mdx","url":"/guides/tree-shaking/","anchors":[{"title":"Add a Utility","id":"add-a-utility","level":2},{"title":"Mark the file as side-effect-free","id":"mark-the-file-as-side-effect-free","level":2},{"title":"Clarifying tree shaking and sideEffects","id":"clarifying-tree-shaking-and-sideeffects","level":2},{"title":"Mark a function call as side-effect-free","id":"mark-a-function-call-as-side-effect-free","level":2},{"title":"Minify the Output","id":"minify-the-output","level":2},{"title":"Conclusion","id":"conclusion","level":2}],"title":"Tree Shaking","sort":16,"contributors":["simon04","zacanger","alexjoverm","avant1","MijaelWatts","dmitriid","probablyup","gish","lumo10","byzyk","pnevares","EugeneHlushko","AnayaDesign","torifat","rahul3v","snitin315"],"related":[{"title":"Debugging Optimization Bailouts","url":"https://webpack.js.org/plugins/module-concatenation-plugin/#debugging-optimization-bailouts"},{"title":"Issue 6074 - Add support for more complex selectors for sideEffects","url":"https://github.com/webpack/webpack/issues/6074"}]},{"path":"src/content/guides/production.mdx","name":"production.mdx","size":9195,"type":"file","extension":".mdx","url":"/guides/production/","anchors":[{"title":"Setup","id":"setup","level":2},{"title":"NPM Scripts","id":"npm-scripts","level":2},{"title":"Specify the Mode","id":"specify-the-mode","level":2},{"title":"Minification","id":"minification","level":2},{"title":"Source Mapping","id":"source-mapping","level":2},{"title":"Minimize CSS","id":"minimize-css","level":2},{"title":"CLI Alternatives","id":"cli-alternatives","level":2}],"title":"Production","sort":17,"contributors":["henriquea","rajagopal4890","makuzaverite","markerikson","simon04","kisnows","chrisVillanueva","swapnilmishra","bring2dip","redian","skipjack","xgqfrms","kelset","xgirma","mehrdaad","SevenOutman","AnayaDesign","wizardofhogwarts","aholzner","EugeneHlushko","snitin315"]},{"path":"src/content/guides/lazy-loading.mdx","name":"lazy-loading.mdx","size":4299,"type":"file","extension":".mdx","url":"/guides/lazy-loading/","anchors":[{"title":"Example","id":"example","level":2},{"title":"Frameworks","id":"frameworks","level":2}],"title":"Lazy Loading","sort":18,"contributors":["iammerrick","chrisVillanueva","skipjack","byzyk","EugeneHlushko","AnayaDesign","tapanprakasht","snitin315"],"related":[{"title":"Lazy Loading ES2015 Modules in the Browser","url":"https://dzone.com/articles/lazy-loading-es2015-modules-in-the-browser"},{"title":"Asynchronous vs Deferred JavaScript","url":"https://bitsofco.de/async-vs-defer/"}]},{"path":"src/content/guides/ecma-script-modules.mdx","name":"ecma-script-modules.mdx","size":3017,"type":"file","extension":".mdx","url":"/guides/ecma-script-modules/","anchors":[{"title":"Exporting","id":"exporting","level":2},{"title":"Importing","id":"importing","level":2},{"title":"Flagging modules as ESM","id":"flagging-modules-as-esm","level":2}],"title":"ECMAScript Modules","sort":19,"contributors":["sokra"],"related":[{"title":"ECMAScript Modules in Node.js","url":"https://nodejs.org/api/esm.html"}]},{"path":"src/content/guides/shimming.mdx","name":"shimming.mdx","size":14898,"type":"file","extension":".mdx","url":"/guides/shimming/","anchors":[{"title":"Shimming Globals","id":"shimming-globals","level":2},{"title":"Granular Shimming","id":"granular-shimming","level":2},{"title":"Global Exports","id":"global-exports","level":2},{"title":"Loading Polyfills","id":"loading-polyfills","level":2},{"title":"Further Optimizations","id":"further-optimizations","level":2},{"title":"Node Built-Ins","id":"node-built-ins","level":2},{"title":"Other Utilities","id":"other-utilities","level":2}],"title":"Shimming","sort":20,"contributors":["pksjce","jhnns","simon04","jeremenichelli","svyandun","byzyk","EugeneHlushko","AnayaDesign","dhurlburtusa","plr108","NicolasLetellier","wizardofhogwarts","snitin315","chenxsan"],"related":[{"title":"Reward modern browser users script","url":"https://medium.com/hackernoon/10-things-i-learned-making-the-fastest-site-in-the-world-18a0e1cdf4a7"},{"title":"useBuiltIns in babel-preset-env","url":"https://babeljs.io/docs/en/babel-preset-env#usebuiltins"}]},{"path":"src/content/guides/typescript.mdx","name":"typescript.mdx","size":6914,"type":"file","extension":".mdx","url":"/guides/typescript/","anchors":[{"title":"Basic Setup","id":"basic-setup","level":2},{"title":"Loader","id":"loader","level":2},{"title":"Source Maps","id":"source-maps","level":2},{"title":"Client types","id":"client-types","level":2},{"title":"Using Third Party Libraries","id":"using-third-party-libraries","level":2},{"title":"Importing Other Assets","id":"importing-other-assets","level":2},{"title":"Build Performance","id":"build-performance","level":2}],"title":"TypeScript","sort":21,"contributors":["morsdyce","kkamali","mtrivera","byzyk","EugeneHlushko","chenxsan","snitin315"]},{"path":"src/content/guides/web-workers.mdx","name":"web-workers.mdx","size":2026,"type":"file","extension":".mdx","url":"/guides/web-workers/","anchors":[{"title":"Syntax","id":"syntax","level":2},{"title":"Example","id":"example","level":2},{"title":"Node.js","id":"nodejs","level":2}],"title":"Web Workers","sort":21,"contributors":["chenxsan"]},{"path":"src/content/guides/progressive-web-application.mdx","name":"progressive-web-application.mdx","size":6018,"type":"file","extension":".mdx","url":"/guides/progressive-web-application/","anchors":[{"title":"We Don\'t Work Offline Now","id":"we-dont-work-offline-now","level":2},{"title":"Adding Workbox","id":"adding-workbox","level":2},{"title":"Registering Our Service Worker","id":"registering-our-service-worker","level":2},{"title":"Conclusion","id":"conclusion","level":2}],"title":"Progressive Web Application","sort":22,"contributors":["johnnyreilly","chenxsan","EugeneHlushko","benschac","aholzner"]},{"path":"src/content/guides/public-path.mdx","name":"public-path.mdx","size":3070,"type":"file","extension":".mdx","url":"/guides/public-path/","anchors":[{"title":"Use Cases","id":"use-cases","level":2},{"title":"Environment Based","id":"environment-based","level":3},{"title":"On The Fly","id":"on-the-fly","level":3},{"title":"Automatic publicPath","id":"automatic-publicpath","level":3}],"title":"Public Path","sort":23,"contributors":["rafaelrinaldi","chrisVillanueva","gonzoyumo","chenxsan"]},{"path":"src/content/guides/integrations.mdx","name":"integrations.mdx","size":5414,"type":"file","extension":".mdx","url":"/guides/integrations/","anchors":[{"title":"NPM Scripts","id":"npm-scripts","level":2},{"title":"Grunt","id":"grunt","level":2},{"title":"Gulp","id":"gulp","level":2},{"title":"Mocha","id":"mocha","level":2},{"title":"Karma","id":"karma","level":2}],"title":"Integrations","sort":24,"contributors":["pksjce","bebraw","tashian","skipjack","AnayaDesign"]},{"path":"src/content/guides/asset-modules.mdx","name":"asset-modules.mdx","size":11519,"type":"file","extension":".mdx","url":"/guides/asset-modules/","anchors":[{"title":"Resource assets","id":"resource-assets","level":2},{"title":"Custom output filename","id":"custom-output-filename","level":3},{"title":"Inlining assets","id":"inlining-assets","level":2},{"title":"Custom data URI generator","id":"custom-data-uri-generator","level":3},{"title":"Source assets","id":"source-assets","level":2},{"title":"URL assets","id":"url-assets","level":2},{"title":"General asset type","id":"general-asset-type","level":2},{"title":"Replacing Inline Loader Syntax","id":"replacing-inline-loader-syntax","level":2},{"title":"Disable emitting assets","id":"disable-emitting-assets","level":2}],"title":"Asset Modules","sort":25,"contributors":["smelukov","EugeneHlushko","chenxsan","anshumanv","spence-s","dkdk225"],"related":[{"title":"webpack 5 - Asset Modules","url":"https://dev.to/smelukov/webpack-5-asset-modules-2o3h"}]},{"path":"src/content/guides/entry-advanced.mdx","name":"entry-advanced.mdx","size":2072,"type":"file","extension":".mdx","url":"/guides/entry-advanced/","anchors":[{"title":"Multiple file types per entry","id":"multiple-file-types-per-entry","level":2}],"title":"Advanced entry","sort":25,"contributors":["EugeneHlushko"]},{"path":"src/content/guides/package-exports.mdx","name":"package-exports.mdx","size":24715,"type":"file","extension":".mdx","url":"/guides/package-exports/","anchors":[{"title":"General syntax","id":"general-syntax","level":2},{"title":"Alternatives","id":"alternatives","level":2},{"title":"Conditional syntax","id":"conditional-syntax","level":2},{"title":"Abbreviation","id":"abbreviation","level":2},{"title":"Notes about ordering","id":"notes-about-ordering","level":2},{"title":"Support","id":"support","level":2},{"title":"Conditions","id":"conditions","level":2},{"title":"Reference syntax","id":"reference-syntax","level":3},{"title":"Optimizations","id":"optimizations","level":3},{"title":"Target environment","id":"target-environment","level":3},{"title":"Conditions: Preprocessor and runtimes","id":"conditions-preprocessor-and-runtimes","level":3},{"title":"Conditions: Custom","id":"conditions-custom","level":3},{"title":"Common patterns","id":"common-patterns","level":2},{"title":"Target environment independent packages","id":"target-environment-independent-packages","level":3},{"title":"Providing devtools or production optimizations","id":"providing-devtools-or-production-optimizations","level":3},{"title":"Providing different versions depending on target environment","id":"providing-different-versions-depending-on-target-environment","level":3},{"title":"Combining patterns","id":"combining-patterns","level":3},{"title":"Guidelines","id":"guidelines","level":2}],"title":"Package exports","sort":25,"contributors":["sokra"],"related":[{"title":"Package entry points in Node.js","url":"https://nodejs.org/api/packages.html#packages_package_entry_points"}]}],"size":240480,"type":"directory","url":"/guides/"},{"path":"src/content/loaders","name":"loaders","children":[{"path":"src/content/loaders/_babel-loader.mdx","name":"babel-loader.mdx","size":13793,"type":"file","extension":".mdx","url":"/loaders/babel-loader/","anchors":[{"title":"Install","id":"install","level":2},{"title":"Usage","id":"usage","level":2},{"title":"Options","id":"options","level":3},{"title":"Troubleshooting","id":"troubleshooting","level":2},{"title":"babel-loader is slow!","id":"babel-loader-is-slow","level":3},{"title":"Some files in my node_modules are not transpiled for IE 11","id":"some-files-in-my-node_modules-are-not-transpiled-for-ie-11","level":3},{"title":"Babel is injecting helpers into each file and bloating my code!","id":"babel-is-injecting-helpers-into-each-file-and-bloating-my-code","level":3},{"title":"The Node.js API for babel has been moved to babel-core.","id":"the-nodejs-api-for-babel-has-been-moved-to-babel-core","level":3},{"title":"Exclude libraries that should not be transpiled","id":"exclude-libraries-that-should-not-be-transpiled","level":3},{"title":"Top level function (IIFE) is still arrow (on Webpack 5)","id":"top-level-function-iife-is-still-arrow-on-webpack-5","level":3},{"title":"Customize config based on webpack target","id":"customize-config-based-on-webpack-target","level":2},{"title":"Customized Loader","id":"customized-loader","level":2},{"title":"Example","id":"example","level":3},{"title":"customOptions(options: Object): { custom: Object, loader: Object }","id":"customoptionsoptions-object--custom-object-loader-object-","level":3},{"title":"config(cfg: PartialConfig, options: { source, customOptions }): Object","id":"configcfg-partialconfig-options--source-customoptions--object","level":3},{"title":"result(result: Result): Result","id":"resultresult-result-result","level":3},{"title":"License","id":"license","level":2}],"title":"babel-loader","source":"https://raw.githubusercontent.com/babel/babel-loader/main/README.md","edit":"https://github.com/babel/babel-loader/edit/main/README.md","repo":"https://github.com/babel/babel-loader","thirdParty":true},{"path":"src/content/loaders/_coffee-loader.mdx","name":"coffee-loader.mdx","size":5019,"type":"file","extension":".mdx","url":"/loaders/coffee-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"Examples","id":"examples","level":2},{"title":"CoffeeScript and Babel","id":"coffeescript-and-babel","level":3},{"title":"Literate CoffeeScript","id":"literate-coffeescript","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"coffee-loader","source":"https://raw.githubusercontent.com/webpack-contrib/coffee-loader/master/README.md","edit":"https://github.com/webpack-contrib/coffee-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/coffee-loader","thirdParty":true},{"path":"src/content/loaders/_exports-loader.mdx","name":"exports-loader.mdx","size":13582,"type":"file","extension":".mdx","url":"/loaders/exports-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Inline","id":"inline","level":3},{"title":"Using Configuration","id":"using-configuration","level":3},{"title":"Options","id":"options","level":2},{"title":"type","id":"type","level":3},{"title":"exports","id":"exports","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"exports-loader","source":"https://raw.githubusercontent.com/webpack-contrib/exports-loader/master/README.md","edit":"https://github.com/webpack-contrib/exports-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/exports-loader","thirdParty":true},{"path":"src/content/loaders/_expose-loader.mdx","name":"expose-loader.mdx","size":9862,"type":"file","extension":".mdx","url":"/loaders/expose-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Inline","id":"inline","level":2},{"title":"Using Configuration","id":"using-configuration","level":2},{"title":"Options","id":"options","level":2},{"title":"exposes","id":"exposes","level":3},{"title":"globalObject","id":"globalobject","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"expose-loader","source":"https://raw.githubusercontent.com/webpack-contrib/expose-loader/master/README.md","edit":"https://github.com/webpack-contrib/expose-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/expose-loader","thirdParty":true},{"path":"src/content/loaders/_html-loader.mdx","name":"html-loader.mdx","size":24363,"type":"file","extension":".mdx","url":"/loaders/html-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"sources","id":"sources","level":3},{"title":"preprocessor","id":"preprocessor","level":3},{"title":"minimize","id":"minimize","level":3},{"title":"esModule","id":"esmodule","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Disable url resolving using the `` comment","id":"disable-url-resolving-using-the--comment","level":3},{"title":"roots","id":"roots","level":3},{"title":"CDN","id":"cdn","level":3},{"title":"Process script and link tags","id":"process-script-and-link-tags","level":3},{"title":"Templating","id":"templating","level":3},{"title":"PostHTML","id":"posthtml","level":3},{"title":"Export into HTML files","id":"export-into-html-files","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"html-loader","source":"https://raw.githubusercontent.com/webpack-contrib/html-loader/master/README.md","edit":"https://github.com/webpack-contrib/html-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/html-loader","thirdParty":true},{"path":"src/content/loaders/_imports-loader.mdx","name":"imports-loader.mdx","size":17274,"type":"file","extension":".mdx","url":"/loaders/imports-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Inline","id":"inline","level":3},{"title":"Using Configuration","id":"using-configuration","level":3},{"title":"Options","id":"options","level":2},{"title":"type","id":"type","level":3},{"title":"imports","id":"imports","level":3},{"title":"wrapper","id":"wrapper","level":3},{"title":"additionalCode","id":"additionalcode","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"imports-loader","source":"https://raw.githubusercontent.com/webpack-contrib/imports-loader/master/README.md","edit":"https://github.com/webpack-contrib/imports-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/imports-loader","thirdParty":true},{"path":"src/content/loaders/index.mdx","name":"index.mdx","size":4115,"type":"file","extension":".mdx","url":"/loaders/","anchors":[{"title":"Files","id":"files","level":2},{"title":"JSON","id":"json","level":2},{"title":"Transpiling","id":"transpiling","level":2},{"title":"Templating","id":"templating","level":2},{"title":"Styling","id":"styling","level":2},{"title":"Frameworks","id":"frameworks","level":2},{"title":"Awesome","id":"awesome","level":2}],"title":"Loaders","sort":-1,"contributors":["simon04","bajras","rhys-vdw","EugeneHlushko","hemal7735","snitin315","anshumanv","jamesgeorge007","chenxsan"]},{"path":"src/content/loaders/_node-loader.mdx","name":"node-loader.mdx","size":5276,"type":"file","extension":".mdx","url":"/loaders/node-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Inline","id":"inline","level":3},{"title":"Configuration","id":"configuration","level":3},{"title":"Options","id":"options","level":2},{"title":"flags","id":"flags","level":3},{"title":"name","id":"name","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"node-loader","source":"https://raw.githubusercontent.com/webpack-contrib/node-loader/master/README.md","edit":"https://github.com/webpack-contrib/node-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/node-loader","thirdParty":true},{"path":"src/content/loaders/_remark-loader.mdx","name":"remark-loader.mdx","size":8153,"type":"file","extension":".mdx","url":"/loaders/remark-loader/","anchors":[{"title":"Usage","id":"usage","level":2},{"title":"Options","id":"options","level":2},{"title":"remarkOptions","id":"remarkoptions","level":3},{"title":"removeFrontMatter","id":"removefrontmatter","level":3},{"title":"Inspiration","id":"inspiration","level":2},{"title":"Examples","id":"examples","level":2},{"title":"Markdown to HTML","id":"markdown-to-html","level":3},{"title":"Markdown to Markdown","id":"markdown-to-markdown","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"remark-loader","source":"https://raw.githubusercontent.com/webpack-contrib/remark-loader/master/README.md","edit":"https://github.com/webpack-contrib/remark-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/remark-loader","thirdParty":true},{"path":"src/content/loaders/_source-map-loader.mdx","name":"source-map-loader.mdx","size":5406,"type":"file","extension":".mdx","url":"/loaders/source-map-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"filterSourceMappingUrl","id":"filtersourcemappingurl","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Ignoring Warnings","id":"ignoring-warnings","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"source-map-loader","source":"https://raw.githubusercontent.com/webpack-contrib/source-map-loader/master/README.md","edit":"https://github.com/webpack-contrib/source-map-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/source-map-loader","thirdParty":true},{"path":"src/content/loaders/_thread-loader.mdx","name":"thread-loader.mdx","size":4455,"type":"file","extension":".mdx","url":"/loaders/thread-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Examples","id":"examples","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"thread-loader","source":"https://raw.githubusercontent.com/webpack-contrib/thread-loader/master/README.md","edit":"https://github.com/webpack-contrib/thread-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/thread-loader","thirdParty":true},{"path":"src/content/loaders/_val-loader.mdx","name":"val-loader.mdx","size":10033,"type":"file","extension":".mdx","url":"/loaders/val-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"executableFile","id":"executablefile","level":3},{"title":"Return Object Properties","id":"return-object-properties","level":2},{"title":"code","id":"code","level":3},{"title":"sourceMap","id":"sourcemap","level":3},{"title":"ast","id":"ast","level":3},{"title":"dependencies","id":"dependencies","level":3},{"title":"contextDependencies","id":"contextdependencies","level":3},{"title":"buildDependencies","id":"builddependencies","level":3},{"title":"cacheable","id":"cacheable","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Simple","id":"simple","level":3},{"title":"Modernizr","id":"modernizr","level":3},{"title":"Figlet","id":"figlet","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"val-loader","source":"https://raw.githubusercontent.com/webpack-contrib/val-loader/master/README.md","edit":"https://github.com/webpack-contrib/val-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/val-loader","thirdParty":true},{"path":"src/content/loaders/_css-loader.mdx","name":"css-loader.mdx","size":45788,"type":"file","extension":".mdx","url":"/loaders/css-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"url","id":"url","level":3},{"title":"import","id":"import","level":3},{"title":"modules","id":"modules","level":3},{"title":"importLoaders","id":"importloaders","level":3},{"title":"sourceMap","id":"sourcemap","level":3},{"title":"esModule","id":"esmodule","level":3},{"title":"exportType","id":"exporttype","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Recommend","id":"recommend","level":3},{"title":"Disable url resolving using the /* webpackIgnore: true */ comment","id":"disable-url-resolving-using-the--webpackignore-true--comment","level":3},{"title":"Assets","id":"assets","level":3},{"title":"Extract","id":"extract","level":3},{"title":"Pure CSS, CSS modules and PostCSS","id":"pure-css-css-modules-and-postcss","level":3},{"title":"Resolve unresolved URLs using an alias","id":"resolve-unresolved-urls-using-an-alias","level":3},{"title":"Named export with custom export names","id":"named-export-with-custom-export-names","level":3},{"title":"Separating Interoperable CSS-only and CSS Module features","id":"separating-interoperable-css-only-and-css-module-features","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"css-loader","source":"https://raw.githubusercontent.com/webpack-contrib/css-loader/master/README.md","edit":"https://github.com/webpack-contrib/css-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/css-loader","thirdParty":true,"group":"CSS"},{"path":"src/content/loaders/_less-loader.mdx","name":"less-loader.mdx","size":15774,"type":"file","extension":".mdx","url":"/loaders/less-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"lessOptions","id":"lessoptions","level":3},{"title":"additionalData","id":"additionaldata","level":3},{"title":"sourceMap","id":"sourcemap","level":3},{"title":"webpackImporter","id":"webpackimporter","level":3},{"title":"implementation","id":"implementation","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Normal usage","id":"normal-usage","level":3},{"title":"Source maps","id":"source-maps","level":3},{"title":"In production","id":"in-production","level":3},{"title":"Imports","id":"imports","level":3},{"title":"Plugins","id":"plugins","level":3},{"title":"Extracting style sheets","id":"extracting-style-sheets","level":3},{"title":"CSS modules gotcha","id":"css-modules-gotcha","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"less-loader","source":"https://raw.githubusercontent.com/webpack-contrib/less-loader/master/README.md","edit":"https://github.com/webpack-contrib/less-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/less-loader","thirdParty":true,"group":"CSS"},{"path":"src/content/loaders/_postcss-loader.mdx","name":"postcss-loader.mdx","size":25177,"type":"file","extension":".mdx","url":"/loaders/postcss-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"execute","id":"execute","level":3},{"title":"postcssOptions","id":"postcssoptions","level":3},{"title":"sourceMap","id":"sourcemap","level":3},{"title":"implementation","id":"implementation","level":3},{"title":"Examples","id":"examples","level":2},{"title":"SugarSS","id":"sugarss","level":3},{"title":"Autoprefixer","id":"autoprefixer","level":3},{"title":"PostCSS Preset Env","id":"postcss-preset-env","level":3},{"title":"CSS Modules","id":"css-modules","level":3},{"title":"Extract CSS","id":"extract-css","level":3},{"title":"Emit assets","id":"emit-assets","level":3},{"title":"Add dependencies, contextDependencies, buildDependencies, missingDependencies","id":"add-dependencies-contextdependencies-builddependencies-missingdependencies","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"postcss-loader","source":"https://raw.githubusercontent.com/webpack-contrib/postcss-loader/master/README.md","edit":"https://github.com/webpack-contrib/postcss-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/postcss-loader","thirdParty":true,"group":"CSS"},{"path":"src/content/loaders/_sass-loader.mdx","name":"sass-loader.mdx","size":24121,"type":"file","extension":".mdx","url":"/loaders/sass-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"The outputStyle (old API) and style (new API) options in production mode","id":"the-outputstyle-old-api-and-style-new-api-options-in-production-mode","level":3},{"title":"Resolving import at-rules","id":"resolving-import-at-rules","level":3},{"title":"Problems with url(...)","id":"problems-with-url","level":3},{"title":"Options","id":"options","level":2},{"title":"implementation","id":"implementation","level":3},{"title":"sassOptions","id":"sassoptions","level":3},{"title":"sourceMap","id":"sourcemap","level":3},{"title":"additionalData","id":"additionaldata","level":3},{"title":"webpackImporter","id":"webpackimporter","level":3},{"title":"warnRuleAsWarning","id":"warnruleaswarning","level":3},{"title":"api","id":"api","level":3},{"title":"How to enable @debug output","id":"how-to-enable-debug-output","level":2},{"title":"Examples","id":"examples","level":2},{"title":"Extracts CSS into separate files","id":"extracts-css-into-separate-files","level":3},{"title":"Source maps","id":"source-maps","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"sass-loader","source":"https://raw.githubusercontent.com/webpack-contrib/sass-loader/master/README.md","edit":"https://github.com/webpack-contrib/sass-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/sass-loader","thirdParty":true,"group":"CSS"},{"path":"src/content/loaders/_style-loader.mdx","name":"style-loader.mdx","size":27281,"type":"file","extension":".mdx","url":"/loaders/style-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"injectType","id":"injecttype","level":3},{"title":"attributes","id":"attributes","level":3},{"title":"insert","id":"insert","level":3},{"title":"styleTagTransform","id":"styletagtransform","level":3},{"title":"base","id":"base","level":3},{"title":"esModule","id":"esmodule","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Recommend","id":"recommend","level":3},{"title":"Named export for CSS Modules","id":"named-export-for-css-modules","level":3},{"title":"Source maps","id":"source-maps","level":3},{"title":"Nonce","id":"nonce","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"style-loader","source":"https://raw.githubusercontent.com/webpack-contrib/style-loader/master/README.md","edit":"https://github.com/webpack-contrib/style-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/style-loader","thirdParty":true,"group":"CSS"},{"path":"src/content/loaders/_stylus-loader.mdx","name":"stylus-loader.mdx","size":18226,"type":"file","extension":".mdx","url":"/loaders/stylus-loader/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"stylusOptions","id":"stylusoptions","level":3},{"title":"sourceMap","id":"sourcemap","level":3},{"title":"webpackImporter","id":"webpackimporter","level":3},{"title":"additionalData","id":"additionaldata","level":3},{"title":"implementation","id":"implementation","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Normal usage","id":"normal-usage","level":3},{"title":"Source maps","id":"source-maps","level":3},{"title":"Using nib with stylus","id":"using-nib-with-stylus","level":3},{"title":"Import JSON files","id":"import-json-files","level":3},{"title":"In production","id":"in-production","level":3},{"title":"webpack resolver","id":"webpack-resolver","level":3},{"title":"Stylus resolver","id":"stylus-resolver","level":3},{"title":"Extracting style sheets","id":"extracting-style-sheets","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"stylus-loader","source":"https://raw.githubusercontent.com/webpack-contrib/stylus-loader/master/README.md","edit":"https://github.com/webpack-contrib/stylus-loader/edit/master/README.md","repo":"https://github.com/webpack-contrib/stylus-loader","thirdParty":true,"group":"CSS"}],"size":277698,"type":"directory","url":"/loaders/"},{"path":"src/content/migrate","name":"migrate","children":[{"path":"src/content/migrate/index.mdx","name":"index.mdx","size":161,"type":"file","extension":".mdx","url":"/migrate/","anchors":[],"title":"Migrate","sort":-1,"contributors":["EugeneHlushko"]},{"path":"src/content/migrate/5.mdx","name":"5.mdx","size":15701,"type":"file","extension":".mdx","url":"/migrate/5/","anchors":[{"title":"Preparations","id":"preparations","level":2},{"title":"Upgrade webpack 4 and its plugins/loaders","id":"upgrade-webpack-4-and-its-pluginsloaders","level":2},{"title":"Make sure your build has no errors or warnings","id":"make-sure-your-build-has-no-errors-or-warnings","level":3},{"title":"Make sure to use mode","id":"make-sure-to-use-mode","level":3},{"title":"Update outdated options","id":"update-outdated-options","level":3},{"title":"Test webpack 5 compatibility","id":"test-webpack-5-compatibility","level":3},{"title":"Upgrade webpack to 5","id":"upgrade-webpack-to-5","level":2},{"title":"Clean up configuration","id":"clean-up-configuration","level":3},{"title":"Need to support an older browser like IE 11?","id":"need-to-support-an-older-browser-like-ie-11","level":3},{"title":"Cleanup the code","id":"cleanup-the-code","level":3},{"title":"Run a single build and follow advice","id":"run-a-single-build-and-follow-advice","level":3},{"title":"Everything works?","id":"everything-works","level":2},{"title":"It is not working?","id":"it-is-not-working","level":2},{"title":"Something missing in this guide?","id":"something-missing-in-this-guide","level":2},{"title":"Changes to internals","id":"changes-to-internals","level":2},{"title":"getOptions method for Loaders","id":"getoptions-method-for-loaders","level":3}],"title":"To v5 from v4","sort":1,"contributors":["sokra","salemhilal","keichinger","EugeneHlushko","MattGoldwater","rramaa","chenxsan","jamesgeorge007","getsnoopy","yevhen-logosha"]},{"path":"src/content/migrate/4.mdx","name":"4.mdx","size":4115,"type":"file","extension":".mdx","url":"/migrate/4/","anchors":[{"title":"Node.js v4","id":"nodejs-v4","level":2},{"title":"CLI","id":"cli","level":2},{"title":"Update plugins","id":"update-plugins","level":2},{"title":"mode","id":"mode","level":2},{"title":"Deprecated/Removed plugins","id":"deprecatedremoved-plugins","level":2},{"title":"CommonsChunkPlugin","id":"commonschunkplugin","level":2},{"title":"import() and CommonJS","id":"import-and-commonjs","level":2},{"title":"json and loaders","id":"json-and-loaders","level":2},{"title":"module.loaders","id":"moduleloaders","level":2}],"title":"To v4 from v3","sort":2,"contributors":["sokra","EugeneHlushko","Kolhar730"],"related":[{"title":"To v2 or v3 from v1","url":"https://webpack.js.org/migrate/3/"},{"title":"RIP CommonChunkPlugin","url":"https://gist.github.com/sokra/1522d586b8e5c0f5072d7565c2bee693"},{"title":"webpack 4: migration guide for plugins/loaders","url":"https://medium.com/webpack/webpack-4-migration-guide-for-plugins-loaders-20a79b927202"}]},{"path":"src/content/migrate/3.mdx","name":"3.mdx","size":16052,"type":"file","extension":".mdx","url":"/migrate/3/","anchors":[{"title":"resolve.root, resolve.fallback, resolve.modulesDirectories","id":"resolveroot-resolvefallback-resolvemodulesdirectories","level":2},{"title":"resolve.extensions","id":"resolveextensions","level":2},{"title":"resolve.*","id":"resolve","level":2},{"title":"module.loaders is now module.rules","id":"moduleloaders-is-now-modulerules","level":2},{"title":"Chaining loaders","id":"chaining-loaders","level":2},{"title":"Automatic -loader module name extension removed","id":"automatic--loader-module-name-extension-removed","level":2},{"title":"json-loader is not required anymore","id":"json-loader-is-not-required-anymore","level":2},{"title":"Loaders in configuration resolve relative to context","id":"loaders-in-configuration-resolve-relative-to-context","level":2},{"title":"module.preLoaders and module.postLoaders were removed:","id":"modulepreloaders-and-modulepostloaders-were-removed","level":2},{"title":"UglifyJsPlugin sourceMap","id":"uglifyjsplugin-sourcemap","level":2},{"title":"UglifyJsPlugin warnings","id":"uglifyjsplugin-warnings","level":2},{"title":"UglifyJsPlugin minimize loaders","id":"uglifyjsplugin-minimize-loaders","level":2},{"title":"DedupePlugin has been removed","id":"dedupeplugin-has-been-removed","level":2},{"title":"BannerPlugin - breaking change","id":"bannerplugin---breaking-change","level":2},{"title":"OccurrenceOrderPlugin is now on by default","id":"occurrenceorderplugin-is-now-on-by-default","level":2},{"title":"ExtractTextWebpackPlugin - breaking change","id":"extracttextwebpackplugin---breaking-change","level":2},{"title":"ExtractTextPlugin.extract","id":"extracttextpluginextract","level":3},{"title":"new ExtractTextPlugin({options})","id":"new-extracttextpluginoptions","level":3},{"title":"Full dynamic requires now fail by default","id":"full-dynamic-requires-now-fail-by-default","level":2},{"title":"Using custom arguments in CLI and configuration","id":"using-custom-arguments-in-cli-and-configuration","level":3},{"title":"require.ensure and AMD require are asynchronous","id":"requireensure-and-amd-require-are-asynchronous","level":2},{"title":"Loader configuration is through options","id":"loader-configuration-is-through-options","level":2},{"title":"What are options?","id":"what-are-options","level":3},{"title":"LoaderOptionsPlugin context","id":"loaderoptionsplugin-context","level":2},{"title":"debug","id":"debug","level":2},{"title":"Code Splitting with ES2015","id":"code-splitting-with-es2015","level":2},{"title":"Dynamic expressions","id":"dynamic-expressions","level":2},{"title":"Mixing ES2015 with AMD and CommonJS","id":"mixing-es2015-with-amd-and-commonjs","level":2},{"title":"Hints","id":"hints","level":2},{"title":"Template strings","id":"template-strings","level":3},{"title":"Configuration Promise","id":"configuration-promise","level":3},{"title":"Advanced loader matching","id":"advanced-loader-matching","level":3},{"title":"More CLI options","id":"more-cli-options","level":3},{"title":"Loader changes","id":"loader-changes","level":2},{"title":"Cacheable","id":"cacheable","level":3},{"title":"Complex options","id":"complex-options","level":3}],"title":"To v2 or v3 from v1","sort":3,"contributors":["sokra","jhnns","grgur","domfarolino","johnnyreilly","jouni-kantola","frederikprijck","chrisVillanueva","bebraw","howdy39","selbekk","ndelangen","EugeneHlushko","byzyk"]}],"size":36029,"type":"directory","url":"/migrate/"},{"path":"src/content/plugins","name":"plugins","children":[{"path":"src/content/plugins/index.mdx","name":"index.mdx","size":4929,"type":"file","extension":".mdx","url":"/plugins/","anchors":[],"title":"Plugins","sort":-1,"contributors":["simon04","gonzoyumo","rouzbeh84","aretecode","eko3alpha","refactorized","byzyk","EugeneHlushko","snitin315","chenxsan"]},{"path":"src/content/plugins/html-webpack-plugin.mdx","name":"html-webpack-plugin.mdx","size":2010,"type":"file","extension":".mdx","url":"/plugins/html-webpack-plugin/","anchors":[{"title":"Installation","id":"installation","level":2},{"title":"Basic Usage","id":"basic-usage","level":2},{"title":"Configuration","id":"configuration","level":2},{"title":"Third party addons","id":"third-party-addons","level":2}],"title":"HtmlWebpackPlugin","group":"Community","contributors":["ampedandwired","simon04","Sibiraj-S","EugeneHlushko"]},{"path":"src/content/plugins/_svg-chunk-webpack-plugin.mdx","name":"svg-chunk-webpack-plugin.mdx","size":8954,"type":"file","extension":".mdx","url":"/plugins/svg-chunk-webpack-plugin/","anchors":[{"title":"When to use this plugin","id":"when-to-use-this-plugin","level":2},{"title":"Zero config","id":"zero-config","level":2},{"title":"Installation","id":"installation","level":2},{"title":"Example","id":"example","level":2},{"title":"Basic usage","id":"basic-usage","level":2},{"title":"Using a configuration","id":"using-a-configuration","level":2},{"title":"Loader","id":"loader","level":3},{"title":"Plugin","id":"plugin","level":3},{"title":"filename","id":"filename","level":3},{"title":"svgstoreConfig","id":"svgstoreconfig","level":3},{"title":"generateSpritesManifest","id":"generatespritesmanifest","level":3},{"title":"generateSpritesPreview","id":"generatespritespreview","level":3},{"title":"Caching","id":"caching","level":2},{"title":"[contenthash]","id":"contenthash","level":3},{"title":"[fullhash]","id":"fullhash","level":3},{"title":"License","id":"license","level":2}],"title":"SvgChunkWebpackPlugin","group":"Community","contributors":["yoriiis","alexander-akait"],"source":"https://raw.githubusercontent.com/yoriiis/svg-chunk-webpack-plugin/main/README.md","edit":"https://github.com/yoriiis/svg-chunk-webpack-plugin/edit/main/README.md","repo":"https://github.com/yoriiis/svg-chunk-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/automatic-prefetch-plugin.mdx","name":"automatic-prefetch-plugin.mdx","size":591,"type":"file","extension":".mdx","url":"/plugins/automatic-prefetch-plugin/","anchors":[],"title":"AutomaticPrefetchPlugin","group":"webpack","contributors":["sokra","EugeneHlushko"]},{"path":"src/content/plugins/banner-plugin.mdx","name":"banner-plugin.mdx","size":1652,"type":"file","extension":".mdx","url":"/plugins/banner-plugin/","anchors":[{"title":"Options","id":"options","level":2},{"title":"Usage","id":"usage","level":2},{"title":"Placeholders","id":"placeholders","level":2}],"title":"BannerPlugin","group":"webpack","contributors":["simon04","byzyk","chenxsan"],"related":[{"title":"banner-plugin-hashing test","url":"https://github.com/webpack/webpack/blob/master/test/configCases/plugins/banner-plugin-hashing/webpack.config.js"}]},{"path":"src/content/plugins/commons-chunk-plugin.mdx","name":"commons-chunk-plugin.mdx","size":9405,"type":"file","extension":".mdx","url":"/plugins/commons-chunk-plugin/","anchors":[{"title":"Options","id":"options","level":2},{"title":"Examples","id":"examples","level":2},{"title":"Commons chunk for entries","id":"commons-chunk-for-entries","level":3},{"title":"Explicit vendor chunk","id":"explicit-vendor-chunk","level":3},{"title":"Move common modules into the parent chunk","id":"move-common-modules-into-the-parent-chunk","level":3},{"title":"Extra async commons chunk","id":"extra-async-commons-chunk","level":3},{"title":"Passing the minChunks property a function","id":"passing-the-minchunks-property-a-function","level":3},{"title":"Manifest file","id":"manifest-file","level":2},{"title":"Combining implicit common vendor chunks and manifest file","id":"combining-implicit-common-vendor-chunks-and-manifest-file","level":2},{"title":"More Examples","id":"more-examples","level":2}],"title":"CommonsChunkPlugin","group":"webpack","contributors":["bebraw","simon04","christopher4lis","kevinzwhuang","jdbevan","jeremenichelli","byzyk","madhavarshney","snitin315"]},{"path":"src/content/plugins/context-exclusion-plugin.mdx","name":"context-exclusion-plugin.mdx","size":516,"type":"file","extension":".mdx","url":"/plugins/context-exclusion-plugin/","anchors":[],"title":"ContextExclusionPlugin","group":"webpack","contributors":["jeffin"]},{"path":"src/content/plugins/context-replacement-plugin.mdx","name":"context-replacement-plugin.mdx","size":3107,"type":"file","extension":".mdx","url":"/plugins/context-replacement-plugin/","anchors":[{"title":"Usage","id":"usage","level":2},{"title":"Content Callback","id":"content-callback","level":2},{"title":"Other Options","id":"other-options","level":2}],"title":"ContextReplacementPlugin","group":"webpack","contributors":["simon04","byzyk","masives","chenxsan"],"related":[{"title":"Issue 2783 - ContextReplacementPlugin Description","url":"https://github.com/webpack/webpack/issues/2783#issuecomment-234137265"},{"title":"Using context replacement module for date-fns","url":"https://github.com/date-fns/date-fns/blob/master/docs/webpack.md"}]},{"path":"src/content/plugins/define-plugin.mdx","name":"define-plugin.mdx","size":4474,"type":"file","extension":".mdx","url":"/plugins/define-plugin/","anchors":[{"title":"Usage","id":"usage","level":2},{"title":"Feature Flags","id":"feature-flags","level":2},{"title":"Service URLs","id":"service-urls","level":2},{"title":"Runtime values via runtimeValue","id":"runtime-values-via-runtimevalue","level":2}],"title":"DefinePlugin","group":"webpack","contributors":["simon04","rouzbeh84","byzyk","EugeneHlushko","smonusbonus","chenxsan"]},{"path":"src/content/plugins/dll-plugin.mdx","name":"dll-plugin.mdx","size":5604,"type":"file","extension":".mdx","url":"/plugins/dll-plugin/","anchors":[{"title":"DllPlugin","id":"dllplugin","level":2},{"title":"DllReferencePlugin","id":"dllreferenceplugin","level":2},{"title":"Modes","id":"modes","level":3},{"title":"Usage","id":"usage","level":2},{"title":"Examples","id":"examples","level":2},{"title":"References","id":"references","level":2},{"title":"Source","id":"source","level":3},{"title":"Tests","id":"tests","level":3}],"title":"DllPlugin","group":"webpack","contributors":["aretecode","sokra","opiepj","simon04","skipjack","byzyk","EugeneHlushko","EslamHiko","snitin315"],"related":[{"title":"Code Splitting Example","url":"https://github.com/webpack/webpack/blob/master/examples/explicit-vendor-chunk/README.md"}]},{"path":"src/content/plugins/environment-plugin.mdx","name":"environment-plugin.mdx","size":3629,"type":"file","extension":".mdx","url":"/plugins/environment-plugin/","anchors":[{"title":"Usage","id":"usage","level":2},{"title":"Usage with default values","id":"usage-with-default-values","level":2},{"title":"Use Case: Git Version","id":"use-case-git-version","level":2},{"title":"DotenvPlugin","id":"dotenvplugin","level":2}],"title":"EnvironmentPlugin","group":"webpack","contributors":["simon04","einarlove","rouzbeh84","byzyk"]},{"path":"src/content/plugins/eval-source-map-dev-tool-plugin.mdx","name":"eval-source-map-dev-tool-plugin.mdx","size":2779,"type":"file","extension":".mdx","url":"/plugins/eval-source-map-dev-tool-plugin/","anchors":[{"title":"Options","id":"options","level":2},{"title":"Examples","id":"examples","level":2},{"title":"Basic Use Case","id":"basic-use-case","level":3},{"title":"Exclude Vendor Maps","id":"exclude-vendor-maps","level":3}],"title":"EvalSourceMapDevToolPlugin","group":"webpack","contributors":["johnnyreilly","simon04","kinseyost","byzyk","madhavarshney","koke","jamesgeorge007","anshumanv","EugeneHlushko"],"related":[{"title":"Building Eval Source Maps","url":"https://survivejs.com/webpack/building/source-maps/#sourcemapdevtoolplugin-and-evalsourcemapdevtoolplugin"}]},{"path":"src/content/plugins/hashed-module-ids-plugin.mdx","name":"hashed-module-ids-plugin.mdx","size":1288,"type":"file","extension":".mdx","url":"/plugins/hashed-module-ids-plugin/","anchors":[{"title":"Options","id":"options","level":2},{"title":"Usage","id":"usage","level":2}],"title":"HashedModuleIdsPlugin","group":"webpack","contributors":["shaodahong","byzyk","EslamHiko"]},{"path":"src/content/plugins/hot-module-replacement-plugin.mdx","name":"hot-module-replacement-plugin.mdx","size":608,"type":"file","extension":".mdx","url":"/plugins/hot-module-replacement-plugin/","anchors":[{"title":"Basic Usage","id":"basic-usage","level":2}],"title":"HotModuleReplacementPlugin","group":"webpack","contributors":["skipjack","byzyk","chenxsan","snitin315"],"related":[{"title":"Concepts - Hot Module Replacement","url":"/concepts/hot-module-replacement"},{"title":"API - Hot Module Replacement","url":"/api/hot-module-replacement"}]},{"path":"src/content/plugins/ignore-plugin.mdx","name":"ignore-plugin.mdx","size":2077,"type":"file","extension":".mdx","url":"/plugins/ignore-plugin/","anchors":[{"title":"Using regular expressions","id":"using-regular-expressions","level":2},{"title":"Using filter functions","id":"using-filter-functions","level":2},{"title":"Example of ignoring Moment Locales","id":"example-of-ignoring-moment-locales","level":2}],"title":"IgnorePlugin","group":"webpack","contributors":["simon04","byzyk","DullReferenceException","EugeneHlushko","FadySamirSadek","iamakulov","chenxsan"]},{"path":"src/content/plugins/internal-plugins.mdx","name":"internal-plugins.mdx","size":9140,"type":"file","extension":".mdx","url":"/plugins/internal-plugins/","anchors":[{"title":"environment","id":"environment","level":2},{"title":"NodeEnvironmentPlugin","id":"nodeenvironmentplugin","level":3},{"title":"compiler","id":"compiler","level":2},{"title":"MemoryCachePlugin","id":"memorycacheplugin","level":3},{"title":"ProgressPlugin","id":"progressplugin","level":3},{"title":"RecordIdsPlugin","id":"recordidsplugin","level":3},{"title":"entry","id":"entry","level":2},{"title":"EntryPlugin","id":"entryplugin","level":3},{"title":"PrefetchPlugin","id":"prefetchplugin","level":3},{"title":"output","id":"output","level":2},{"title":"JsonpTemplatePlugin","id":"jsonptemplateplugin","level":3},{"title":"NodeTemplatePlugin","id":"nodetemplateplugin","level":3},{"title":"LibraryTemplatePlugin","id":"librarytemplateplugin","level":3},{"title":"WebWorkerTemplatePlugin","id":"webworkertemplateplugin","level":3},{"title":"EvalDevToolModulePlugin","id":"evaldevtoolmoduleplugin","level":3},{"title":"SourceMapDevToolPlugin","id":"sourcemapdevtoolplugin","level":3},{"title":"HotModuleReplacementPlugin","id":"hotmodulereplacementplugin","level":3},{"title":"source","id":"source","level":2},{"title":"APIPlugin","id":"apiplugin","level":3},{"title":"CompatibilityPlugin","id":"compatibilityplugin","level":3},{"title":"ConstPlugin","id":"constplugin","level":3},{"title":"ProvidePlugin","id":"provideplugin","level":3},{"title":"NodeStuffPlugin","id":"nodestuffplugin","level":3},{"title":"RequireJsStuffPlugin","id":"requirejsstuffplugin","level":3},{"title":"NodeSourcePlugin","id":"nodesourceplugin","level":3},{"title":"NodeTargetPlugin","id":"nodetargetplugin","level":3},{"title":"AMDPlugin","id":"amdplugin","level":3},{"title":"CommonJsPlugin","id":"commonjsplugin","level":3},{"title":"RequireContextPlugin","id":"requirecontextplugin","level":3},{"title":"RequireEnsurePlugin","id":"requireensureplugin","level":3},{"title":"RequireIncludePlugin","id":"requireincludeplugin","level":3},{"title":"DefinePlugin","id":"defineplugin","level":3},{"title":"optimize","id":"optimize","level":2},{"title":"LimitChunkCountPlugin","id":"limitchunkcountplugin","level":3},{"title":"MergeDuplicateChunksPlugin","id":"mergeduplicatechunksplugin","level":3},{"title":"RemoveEmptyChunksPlugin","id":"removeemptychunksplugin","level":3},{"title":"MinChunkSizePlugin","id":"minchunksizeplugin","level":3},{"title":"ModuleConcatenationPlugin","id":"moduleconcatenationplugin","level":3},{"title":"FlagIncludedChunksPlugin","id":"flagincludedchunksplugin","level":3},{"title":"RealContentHashPlugin","id":"realcontenthashplugin","level":3}],"title":"Internal webpack plugins","group":"webpack","contributors":["iAziz786","EugeneHlushko","ooflorent","Legends","chenxsan"]},{"path":"src/content/plugins/limit-chunk-count-plugin.mdx","name":"limit-chunk-count-plugin.mdx","size":1278,"type":"file","extension":".mdx","url":"/plugins/limit-chunk-count-plugin/","anchors":[{"title":"Options","id":"options","level":2},{"title":"maxChunks","id":"maxchunks","level":3},{"title":"minChunkSize","id":"minchunksize","level":3},{"title":"Usage via CLI","id":"usage-via-cli","level":2}],"title":"LimitChunkCountPlugin","group":"webpack","contributors":["rouzbeh84","skipjack","tbroadley","byzyk","EugeneHlushko","erykpiast"]},{"path":"src/content/plugins/min-chunk-size-plugin.mdx","name":"min-chunk-size-plugin.mdx","size":449,"type":"file","extension":".mdx","url":"/plugins/min-chunk-size-plugin/","anchors":[{"title":"Usage via CLI","id":"usage-via-cli","level":2}],"title":"MinChunkSizePlugin","group":"webpack","contributors":["byzyk","erykpiast"]},{"path":"src/content/plugins/module-concatenation-plugin.mdx","name":"module-concatenation-plugin.mdx","size":4259,"type":"file","extension":".mdx","url":"/plugins/module-concatenation-plugin/","anchors":[{"title":"Optimization Bailouts","id":"optimization-bailouts","level":2},{"title":"Module Grouping Algorithm","id":"module-grouping-algorithm","level":3},{"title":"Debugging Optimization Bailouts","id":"debugging-optimization-bailouts","level":3}],"title":"ModuleConcatenationPlugin","group":"webpack","contributors":["skipjack","TheLarkInn","byzyk"]},{"path":"src/content/plugins/module-federation-plugin.mdx","name":"module-federation-plugin.mdx","size":8517,"type":"file","extension":".mdx","url":"/plugins/module-federation-plugin/","anchors":[{"title":"Options","id":"options","level":2},{"title":"runtime","id":"runtime","level":3},{"title":"Sharing libraries","id":"sharing-libraries","level":3}],"title":"ModuleFederationPlugin","group":"webpack","contributors":["XiaofengXie16","chenxsan","burhanuday","christian24"],"related":[{"title":"Module Federation","url":"/concepts/module-federation/"}]},{"path":"src/content/plugins/NoEmitOnErrorsPlugin.mdx","name":"NoEmitOnErrorsPlugin.mdx","size":434,"type":"file","extension":".mdx","url":"/plugins/NoEmitOnErrorsPlugin/","anchors":[],"title":"NoEmitOnErrorsPlugin","group":"webpack","contributors":["jeffin","chenxsan","snitin315"]},{"path":"src/content/plugins/normal-module-replacement-plugin.mdx","name":"normal-module-replacement-plugin.mdx","size":2476,"type":"file","extension":".mdx","url":"/plugins/normal-module-replacement-plugin/","anchors":[{"title":"Basic Example","id":"basic-example","level":2},{"title":"Advanced Example","id":"advanced-example","level":2}],"title":"NormalModuleReplacementPlugin","group":"webpack","contributors":["gonzoyumo","byzyk","chenxsan"]},{"path":"src/content/plugins/prefetch-plugin.mdx","name":"prefetch-plugin.mdx","size":503,"type":"file","extension":".mdx","url":"/plugins/prefetch-plugin/","anchors":[{"title":"Options","id":"options","level":2}],"title":"PrefetchPlugin","group":"webpack","contributors":["skipjack","byzyk"]},{"path":"src/content/plugins/profiling-plugin.mdx","name":"profiling-plugin.mdx","size":937,"type":"file","extension":".mdx","url":"/plugins/profiling-plugin/","anchors":[{"title":"Options","id":"options","level":2},{"title":"Usage: default","id":"usage-default","level":2},{"title":"Usage: custom outputPath","id":"usage-custom-outputpath","level":2}],"title":"ProfilingPlugin","group":"webpack","contributors":["EugeneHlushko","byzyk","akgupta0777"]},{"path":"src/content/plugins/progress-plugin.mdx","name":"progress-plugin.mdx","size":4986,"type":"file","extension":".mdx","url":"/plugins/progress-plugin/","anchors":[{"title":"Usage","id":"usage","level":2},{"title":"Providing function","id":"providing-function","level":3},{"title":"Providing object","id":"providing-object","level":3},{"title":"webpack.ProgressPlugin.createDefaultHandler","id":"webpackprogressplugincreatedefaulthandler","level":3},{"title":"Percentage calculation","id":"percentage-calculation","level":2},{"title":"Supported Hooks","id":"supported-hooks","level":2},{"title":"Source","id":"source","level":2}],"title":"ProgressPlugin","group":"webpack","contributors":["elliottsj","EugeneHlushko","byzyk","smelukov","chenxsan"]},{"path":"src/content/plugins/provide-plugin.mdx","name":"provide-plugin.mdx","size":1893,"type":"file","extension":".mdx","url":"/plugins/provide-plugin/","anchors":[{"title":"Usage: jQuery","id":"usage-jquery","level":2},{"title":"Usage: jQuery with Angular 1","id":"usage-jquery-with-angular-1","level":2},{"title":"Usage: Lodash Map","id":"usage-lodash-map","level":2},{"title":"Usage: Vue.js","id":"usage-vuejs","level":3}],"title":"ProvidePlugin","group":"webpack","contributors":["sokra","simon04","re-fort","byzyk","seckin92"]},{"path":"src/content/plugins/source-map-dev-tool-plugin.mdx","name":"source-map-dev-tool-plugin.mdx","size":4597,"type":"file","extension":".mdx","url":"/plugins/source-map-dev-tool-plugin/","anchors":[{"title":"Options","id":"options","level":2},{"title":"Examples","id":"examples","level":2},{"title":"Basic Use Case","id":"basic-use-case","level":3},{"title":"Exclude Vendor Maps","id":"exclude-vendor-maps","level":3},{"title":"Host Source Maps Externally","id":"host-source-maps-externally","level":3}],"title":"SourceMapDevToolPlugin","group":"webpack","contributors":["johnnyreilly","simon04","neilkennedy","byzyk","EugeneHlushko","chenxsan"],"related":[{"title":"Building Source Maps","url":"https://survivejs.com/webpack/building/source-maps/#-sourcemapdevtoolplugin-and-evalsourcemapdevtoolplugin-"}]},{"path":"src/content/plugins/split-chunks-plugin.mdx","name":"split-chunks-plugin.mdx","size":21411,"type":"file","extension":".mdx","url":"/plugins/split-chunks-plugin/","anchors":[{"title":"Defaults","id":"defaults","level":2},{"title":"Configuration","id":"configuration","level":2},{"title":"optimization.splitChunks","id":"optimizationsplitchunks","level":2},{"title":"splitChunks.automaticNameDelimiter","id":"splitchunksautomaticnamedelimiter","level":3},{"title":"splitChunks.chunks","id":"splitchunkschunks","level":3},{"title":"splitChunks.maxAsyncRequests","id":"splitchunksmaxasyncrequests","level":3},{"title":"splitChunks.maxInitialRequests","id":"splitchunksmaxinitialrequests","level":3},{"title":"splitChunks.defaultSizeTypes","id":"splitchunksdefaultsizetypes","level":3},{"title":"splitChunks.minChunks","id":"splitchunksminchunks","level":3},{"title":"splitChunks.hidePathInfo","id":"splitchunkshidepathinfo","level":3},{"title":"splitChunks.minSize","id":"splitchunksminsize","level":3},{"title":"splitChunks.minSizeReduction","id":"splitchunksminsizereduction","level":3},{"title":"splitChunks.enforceSizeThreshold","id":"splitchunksenforcesizethreshold","level":3},{"title":"splitChunks.minRemainingSize","id":"splitchunksminremainingsize","level":3},{"title":"splitChunks.layer","id":"splitchunkslayer","level":3},{"title":"splitChunks.maxSize","id":"splitchunksmaxsize","level":3},{"title":"splitChunks.maxAsyncSize","id":"splitchunksmaxasyncsize","level":3},{"title":"splitChunks.maxInitialSize","id":"splitchunksmaxinitialsize","level":3},{"title":"splitChunks.name","id":"splitchunksname","level":3},{"title":"splitChunks.usedExports","id":"splitchunksusedexports","level":3},{"title":"splitChunks.cacheGroups","id":"splitchunkscachegroups","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Defaults: Example 1","id":"defaults-example-1","level":3},{"title":"Defaults: Example 2","id":"defaults-example-2","level":3},{"title":"Split Chunks: Example 1","id":"split-chunks-example-1","level":3},{"title":"Split Chunks: Example 2","id":"split-chunks-example-2","level":3},{"title":"Split Chunks: Example 3","id":"split-chunks-example-3","level":3}],"title":"SplitChunksPlugin","group":"webpack","contributors":["sokra","jeremenichelli","Priestch","chrisdothtml","EugeneHlushko","byzyk","jacobangel","madhavarshney","sakhisheikh","superburrito","ryandrew14","snitin315","chenxsan","rohrlaf","jamesgeorge007","anshumanv","snitin315"],"related":[{"title":"webpack\'s automatic deduplication algorithm example","url":"https://github.com/webpack/webpack/blob/master/examples/many-pages/README.md"},{"title":"webpack 4: Code Splitting, chunk graph and the splitChunks optimization","url":"https://medium.com/webpack/webpack-4-code-splitting-chunk-graph-and-the-splitchunks-optimization-be739a861366"}]},{"path":"src/content/plugins/watch-ignore-plugin.mdx","name":"watch-ignore-plugin.mdx","size":552,"type":"file","extension":".mdx","url":"/plugins/watch-ignore-plugin/","anchors":[{"title":"Options","id":"options","level":2}],"title":"WatchIgnorePlugin","group":"webpack","contributors":["skipjack","byzyk","EugeneHlushko"]},{"path":"src/content/plugins/_compression-webpack-plugin.mdx","name":"compression-webpack-plugin.mdx","size":11805,"type":"file","extension":".mdx","url":"/plugins/compression-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"test","id":"test","level":3},{"title":"include","id":"include","level":3},{"title":"exclude","id":"exclude","level":3},{"title":"algorithm","id":"algorithm","level":3},{"title":"compressionOptions","id":"compressionoptions","level":3},{"title":"threshold","id":"threshold","level":3},{"title":"minRatio","id":"minratio","level":3},{"title":"filename","id":"filename","level":3},{"title":"deleteOriginalAssets","id":"deleteoriginalassets","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Using Zopfli","id":"using-zopfli","level":3},{"title":"Using Brotli","id":"using-brotli","level":3},{"title":"Multiple compressed versions of assets for different algorithm","id":"multiple-compressed-versions-of-assets-for-different-algorithm","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"CompressionWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/compression-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/compression-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/compression-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_copy-webpack-plugin.mdx","name":"copy-webpack-plugin.mdx","size":27639,"type":"file","extension":".mdx","url":"/plugins/copy-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"Patterns","id":"patterns","level":3},{"title":"noErrorOnMissing","id":"noerroronmissing","level":3},{"title":"Options","id":"options-1","level":3},{"title":"Examples","id":"examples","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"CopyWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/copy-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/copy-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/copy-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_css-minimizer-webpack-plugin.mdx","name":"css-minimizer-webpack-plugin.mdx","size":16599,"type":"file","extension":".mdx","url":"/plugins/css-minimizer-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Note about source maps","id":"note-about-source-maps","level":2},{"title":"Options","id":"options","level":2},{"title":"test","id":"test","level":3},{"title":"include","id":"include","level":3},{"title":"exclude","id":"exclude","level":3},{"title":"parallel","id":"parallel","level":3},{"title":"minify","id":"minify","level":3},{"title":"minimizerOptions","id":"minimizeroptions","level":3},{"title":"warningsFilter","id":"warningsfilter","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Use sourcemaps","id":"use-sourcemaps","level":3},{"title":"Remove all comments","id":"remove-all-comments","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"CssMinimizerWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/css-minimizer-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/css-minimizer-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/css-minimizer-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_eslint-webpack-plugin.mdx","name":"eslint-webpack-plugin.mdx","size":7728,"type":"file","extension":".mdx","url":"/plugins/eslint-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"cache","id":"cache","level":3},{"title":"cacheLocation","id":"cachelocation","level":3},{"title":"context","id":"context","level":3},{"title":"eslintPath","id":"eslintpath","level":3},{"title":"extensions","id":"extensions","level":3},{"title":"exclude","id":"exclude","level":3},{"title":"resourceQueryExclude","id":"resourcequeryexclude","level":3},{"title":"files","id":"files","level":3},{"title":"fix","id":"fix","level":3},{"title":"formatter","id":"formatter","level":3},{"title":"lintDirtyModulesOnly","id":"lintdirtymodulesonly","level":3},{"title":"threads","id":"threads","level":3},{"title":"Errors and Warning","id":"errors-and-warning","level":3},{"title":"Changelog","id":"changelog","level":2},{"title":"License","id":"license","level":2}],"title":"EslintWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/eslint-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/eslint-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/eslint-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_html-minimizer-webpack-plugin.mdx","name":"html-minimizer-webpack-plugin.mdx","size":15233,"type":"file","extension":".mdx","url":"/plugins/html-minimizer-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"test","id":"test","level":3},{"title":"include","id":"include","level":3},{"title":"exclude","id":"exclude","level":3},{"title":"parallel","id":"parallel","level":3},{"title":"minify","id":"minify","level":3},{"title":"minimizerOptions","id":"minimizeroptions","level":3},{"title":"Examples","id":"examples","level":2},{"title":"swc/html","id":"swchtml","level":3},{"title":"@minify-html/node","id":"minify-htmlnode","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"HtmlMinimizerWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/html-minimizer-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/html-minimizer-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/html-minimizer-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_image-minimizer-webpack-plugin.mdx","name":"image-minimizer-webpack-plugin.mdx","size":63294,"type":"file","extension":".mdx","url":"/plugins/image-minimizer-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Install optimize/generate tool","id":"install-optimizegenerate-tool","level":3},{"title":"Advanced setup","id":"advanced-setup","level":3},{"title":"Plugin Options","id":"plugin-options","level":2},{"title":"test","id":"test","level":3},{"title":"include","id":"include","level":3},{"title":"exclude","id":"exclude","level":3},{"title":"minimizer","id":"minimizer","level":3},{"title":"generator","id":"generator","level":3},{"title":"severityError","id":"severityerror","level":3},{"title":"loader","id":"loader","level":3},{"title":"concurrency","id":"concurrency","level":3},{"title":"deleteOriginalAssets","id":"deleteoriginalassets","level":3},{"title":"Loader Options","id":"loader-options","level":2},{"title":"minimizer","id":"minimizer-1","level":3},{"title":"generator","id":"generator-1","level":3},{"title":"severityError","id":"severityerror-1","level":3},{"title":"Additional API","id":"additional-api","level":2},{"title":"imageminNormalizeConfig(config)","id":"imageminnormalizeconfigconfig","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Optimize images based on size","id":"optimize-images-based-on-size","level":3},{"title":"Optimize and generate webp images","id":"optimize-and-generate-webp-images","level":3},{"title":"Generate webp images from copied assets","id":"generate-webp-images-from-copied-assets","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"ImageMinimizerWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/image-minimizer-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/image-minimizer-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/image-minimizer-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_install-webpack-plugin.mdx","name":"install-webpack-plugin.mdx","size":5303,"type":"file","extension":".mdx","url":"/plugins/install-webpack-plugin/","anchors":[{"title":"Usage","id":"usage","level":1},{"title":"Options","id":"options","level":1},{"title":"dependencies","id":"dependencies","level":2},{"title":"peer","id":"peer","level":3},{"title":"packageManager","id":"packagemanager","level":2},{"title":"type","id":"type","level":3},{"title":"options","id":"options-1","level":3},{"title":"arguments","id":"arguments","level":3},{"title":"dev","id":"dev","level":3},{"title":"quiet","id":"quiet","level":3},{"title":"prompt","id":"prompt","level":2},{"title":"Demo","id":"demo","level":1},{"title":"Features","id":"features","level":1},{"title":"Contributing","id":"contributing","level":2}],"title":"InstallWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/install-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/install-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/install-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_json-minimizer-webpack-plugin.mdx","name":"json-minimizer-webpack-plugin.mdx","size":4876,"type":"file","extension":".mdx","url":"/plugins/json-minimizer-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"test","id":"test","level":3},{"title":"include","id":"include","level":3},{"title":"exclude","id":"exclude","level":3},{"title":"minimizerOptions","id":"minimizeroptions","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"JsonMinimizerWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/json-minimizer-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/json-minimizer-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/json-minimizer-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_mini-css-extract-plugin.mdx","name":"mini-css-extract-plugin.mdx","size":29667,"type":"file","extension":".mdx","url":"/plugins/mini-css-extract-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"Plugin Options","id":"plugin-options","level":3},{"title":"Loader Options","id":"loader-options","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Recommended","id":"recommended","level":3},{"title":"Minimal example","id":"minimal-example","level":3},{"title":"Named export for CSS Modules","id":"named-export-for-css-modules","level":3},{"title":"The publicPath option as function","id":"the-publicpath-option-as-function","level":3},{"title":"Advanced configuration example","id":"advanced-configuration-example","level":3},{"title":"Hot Module Reloading (HMR)","id":"hot-module-reloading-hmr","level":3},{"title":"Minimizing For Production","id":"minimizing-for-production","level":3},{"title":"Using preloaded or inlined CSS","id":"using-preloaded-or-inlined-css","level":3},{"title":"Extracting all CSS in a single file","id":"extracting-all-css-in-a-single-file","level":3},{"title":"Extracting CSS based on entry","id":"extracting-css-based-on-entry","level":3},{"title":"Filename Option as function","id":"filename-option-as-function","level":3},{"title":"Long Term Caching","id":"long-term-caching","level":3},{"title":"Remove Order Warnings","id":"remove-order-warnings","level":3},{"title":"Multiple Themes","id":"multiple-themes","level":3},{"title":"Media Query Plugin","id":"media-query-plugin","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"MiniCssExtractPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/mini-css-extract-plugin/master/README.md","edit":"https://github.com/webpack-contrib/mini-css-extract-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/mini-css-extract-plugin","thirdParty":true},{"path":"src/content/plugins/_stylelint-webpack-plugin.mdx","name":"stylelint-webpack-plugin.mdx","size":7601,"type":"file","extension":".mdx","url":"/plugins/stylelint-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Options","id":"options","level":2},{"title":"cache","id":"cache","level":3},{"title":"cacheLocation","id":"cachelocation","level":3},{"title":"configFile","id":"configfile","level":3},{"title":"context","id":"context","level":3},{"title":"exclude","id":"exclude","level":3},{"title":"extensions","id":"extensions","level":3},{"title":"files","id":"files","level":3},{"title":"fix","id":"fix","level":3},{"title":"formatter","id":"formatter","level":3},{"title":"lintDirtyModulesOnly","id":"lintdirtymodulesonly","level":3},{"title":"stylelintPath","id":"stylelintpath","level":3},{"title":"threads","id":"threads","level":3},{"title":"Errors and Warning","id":"errors-and-warning","level":3},{"title":"Changelog","id":"changelog","level":2},{"title":"License","id":"license","level":2}],"title":"StylelintWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/stylelint-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/stylelint-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/stylelint-webpack-plugin","thirdParty":true},{"path":"src/content/plugins/_terser-webpack-plugin.mdx","name":"terser-webpack-plugin.mdx","size":21559,"type":"file","extension":".mdx","url":"/plugins/terser-webpack-plugin/","anchors":[{"title":"Getting Started","id":"getting-started","level":2},{"title":"Note about source maps","id":"note-about-source-maps","level":2},{"title":"Options","id":"options","level":2},{"title":"test","id":"test","level":3},{"title":"include","id":"include","level":3},{"title":"exclude","id":"exclude","level":3},{"title":"parallel","id":"parallel","level":3},{"title":"minify","id":"minify","level":3},{"title":"terserOptions","id":"terseroptions","level":3},{"title":"extractComments","id":"extractcomments","level":3},{"title":"Examples","id":"examples","level":2},{"title":"Preserve Comments","id":"preserve-comments","level":3},{"title":"Remove Comments","id":"remove-comments","level":3},{"title":"Custom Minify Function","id":"custom-minify-function","level":3},{"title":"Typescript","id":"typescript","level":3},{"title":"Contributing","id":"contributing","level":2},{"title":"License","id":"license","level":2}],"title":"TerserWebpackPlugin","group":"webpack contrib","source":"https://raw.githubusercontent.com/webpack-contrib/terser-webpack-plugin/master/README.md","edit":"https://github.com/webpack-contrib/terser-webpack-plugin/edit/master/README.md","repo":"https://github.com/webpack-contrib/terser-webpack-plugin","thirdParty":true}],"size":324359,"type":"directory","url":"/plugins/"},{"path":"src/content/index.mdx","name":"index.mdx","size":940,"type":"file","extension":".mdx","url":"/","anchors":[{"title":"Write Your Code","id":"write-your-code","level":2},{"title":"Bundle It","id":"bundle-it","level":2},{"title":"Awesome isn\'t it? Let\'s dive in!","id":"awesome-isnt-it-lets-dive-in","level":2}],"title":"webpack","sort":-1},{"path":"src/content/comparison.mdx","name":"comparison.mdx","size":18878,"type":"file","extension":".mdx","url":"/comparison/","anchors":[{"title":"Bundling vs. Loading","id":"bundling-vs-loading","level":2}],"title":"Comparison","sort":1,"contributors":["pksjce","bebraw","chrisVillanueva","tashian","simon04","byzyk"],"related":[{"title":"JSPM vs. webpack","url":"https://ilikekillnerds.com/2015/07/jspm-vs-webpack/"},{"title":"webpack vs. Browserify vs. SystemJS","url":"https://engineering.velocityapp.com/webpack-vs-browersify-vs-systemjs-for-spas-95b349a41fa0"}]},{"path":"src/content/awesome-webpack.mdx","name":"awesome-webpack.mdx","size":43053,"type":"file","extension":".mdx","url":"/awesome-webpack/","anchors":[{"title":"Webpack Ecosystem","id":"webpack-ecosystem","level":2},{"title":"Support Webpack","id":"support-webpack","level":3},{"title":"Community","id":"community","level":3},{"title":"Twitter","id":"twitter","level":3},{"title":"Libraries","id":"libraries","level":2},{"title":"Loaders","id":"loaders","level":3},{"title":"Integration Libraries","id":"integration-libraries","level":3},{"title":"Webpack Plugins","id":"webpack-plugins","level":3},{"title":"Webpack Tools","id":"webpack-tools","level":3},{"title":"Research & Training","id":"research--training","level":2},{"title":"Articles","id":"articles","level":3},{"title":"Videos","id":"videos","level":3},{"title":"Courses","id":"courses","level":3},{"title":"Books","id":"books","level":3},{"title":"Webpack Examples","id":"webpack-examples","level":3},{"title":"Community Examples","id":"community-examples","level":3},{"title":"Other","id":"other","level":3}],"title":"Awesome webpack","sort":2,"contributors":["snitin315","licg9999"]},{"path":"src/content/branding.mdx","name":"branding.mdx","size":5677,"type":"file","extension":".mdx","url":"/branding/","anchors":[{"title":"The Name","id":"the-name","level":2},{"title":"Logo","id":"logo","level":2},{"title":"Icon only","id":"icon-only","level":2},{"title":"Color Palette","id":"color-palette","level":2},{"title":"License","id":"license","level":2}],"title":"Branding Guidelines","sort":2,"contributors":["jhnns","skipjack","rouzbeh84","byzyk"]},{"path":"src/content/glossary.mdx","name":"glossary.mdx","size":5804,"type":"file","extension":".mdx","url":"/glossary/","anchors":[{"title":"A","id":"a","level":2},{"title":"B","id":"b","level":2},{"title":"C","id":"c","level":2},{"title":"D","id":"d","level":2},{"title":"E","id":"e","level":2},{"title":"H","id":"h","level":2},{"title":"L","id":"l","level":2},{"title":"M","id":"m","level":2},{"title":"O","id":"o","level":2},{"title":"P","id":"p","level":2},{"title":"R","id":"r","level":2},{"title":"S","id":"s","level":2},{"title":"T","id":"t","level":2},{"title":"V","id":"v","level":2},{"title":"W","id":"w","level":2}],"title":"Glossary","sort":3,"contributors":["kryptokinght","rouzbeh84","bebraw","skipjack","byzyk","pranshuchittora","jamesgeorge007"]},{"path":"src/content/license.mdx","name":"license.mdx","size":772,"type":"file","extension":".mdx","url":"/license/","anchors":[{"title":"webpack","id":"webpack","level":2},{"title":"webpack logo and icon","id":"webpack-logo-and-icon","level":2},{"title":"webpack documentation","id":"webpack-documentation","level":2},{"title":"webpack code samples","id":"webpack-code-samples","level":2}],"title":"License","sort":5,"contributors":["EugeneHlushko","pranshuchittora"]}],"size":1667429,"type":"directory","url":"/"}');const mt={Badge:nt,StackBlitzPreview:ot,a:at};function ht(e){const t=(0,s.TH)(),l=(0,s.s0)(),[n,o]=(0,r.useState)(!1),a=()=>{o(!n)},c=e=>{let t=e.findIndex((e=>"index.mdx"===e.name.toLowerCase()));return-1!==t&&(e.unshift(e[t]),e.splice(t+1,1)),e.map((e=>{let{title:t,name:i,url:l,group:n,sort:s,anchors:o,children:a}=e;return{title:t||i,content:t||i,url:l,group:n,sort:s,anchors:o,children:a?c(a):[]}})).filter((e=>"printable.mdx"!==e.title&&!e.content.includes("Printable")))};(0,r.useEffect)((()=>{"serviceWorker"in navigator&&navigator.serviceWorker.addEventListener("controllerchange",(()=>{window.location.reload()}))}),[]),(0,r.useEffect)((()=>{b()&&"serviceWorker"in navigator&&i.e(3790).then(i.bind(i,3790)).then((e=>{let{Workbox:t}=e;const i=new t("/sw.js");i.addEventListener("waiting",(()=>{console.log("A new service worker has installed, but it can't activate until all tabs running the current version have been unloaded")})),i.register()}))}),[]);let p=ut.children.filter((e=>"directory"===e.type)),u=p.find((e=>{let{url:i}=e;return t.pathname.startsWith(i)})),v=h(ut).filter((e=>".md"===e.extension||".mdx"===e.extension));const x=c(u?u.children:ut.children.filter((e=>"directory"!==e.type&&"/"!==e.url))),k=["contribute","blog"],y=((e,t)=>{const i=g(e,(e=>e.url===t));return i?i?t.includes("/printable")?"Combined printable page | webpack":"/"===t?i.title||"webpack":`${i.title} | webpack`:void 0:"webpack"})(ut,t.pathname),w=((e,t)=>{const i=g(e,(e=>e.url===t));if(i)return t.includes("/printable")?"":i.description||""})(ut,t.pathname)||"webpack is a module bundler. Its main purpose is to bundle JavaScript files for usage in a browser, yet it is also capable of transforming, bundling, or packaging just about any resource or asset.";return(0,r.useEffect)((()=>{const e=function(e){return!("/configuration/other-options/"!==e.pathname||!e.hash.startsWith("#cache"))&&`/configuration/cache/${e.hash}`}(t);e&&l(e,{replace:!0})}),[t,l]),(0,d.jsx)(m.Zo,{components:mt,children:(0,d.jsxs)("div",{className:"site",children:[(0,d.jsxs)(rt.ql,{children:[(0,d.jsx)("html",{lang:"en"}),(0,d.jsx)("meta",{charset:"utf-8"}),(0,d.jsx)("meta",{name:"theme-color",content:"#2B3A42"}),(0,d.jsx)("meta",{name:"viewport",content:"width=device-width, initial-scale=1"}),function(e){return e.includes("/printable")}(t.pathname)?(0,d.jsx)("meta",{name:"robots",content:"noindex,nofollow"}):null,(0,d.jsx)("title",{children:y}),(0,d.jsx)("meta",{name:"description",content:w}),(0,d.jsx)("meta",{property:"og:site_name",content:"webpack"}),(0,d.jsx)("meta",{property:"og:type",content:"website"}),(0,d.jsx)("meta",{property:"og:title",content:y}),(0,d.jsx)("meta",{property:"og:description",name:"description",content:w}),(0,d.jsx)("meta",{property:"og:image",content:`https://webpack.js.org${pt}`}),(0,d.jsx)("meta",{property:"twitter:card",content:"summary"}),(0,d.jsx)("meta",{property:"twitter:site",content:"@webpack"}),(0,d.jsx)("meta",{property:"twitter:creator",content:"@webpack"}),(0,d.jsx)("meta",{property:"twitter:domain",content:"https://webpack.js.org/"}),(0,d.jsx)("link",{rel:"icon",type:"image/x-icon",href:dt}),(0,d.jsx)("link",{rel:"manifest",href:"/manifest.json"}),(0,d.jsx)("link",{rel:"canonical",href:`https://webpack.js.org${function(e){return e.replace(/\/?$/,"/")}(t.pathname)}`}),(0,d.jsx)("meta",{name:"mobile-web-app-capable",content:"yes"}),(0,d.jsx)("link",{rel:"icon",sizes:"192x192",href:"/icon_192x192.png"}),(0,d.jsx)("link",{rel:"icon",sizes:"512x512",href:"/icon_512x512.png"}),(0,d.jsx)("meta",{name:"apple-mobile-web-app-capable",content:"yes"}),(0,d.jsx)("meta",{name:"apple-mobile-web-app-status-bar-style",content:"black"}),(0,d.jsx)("meta",{name:"apple-mobile-web-app-title",content:"webpack"}),(0,d.jsx)("link",{rel:"apple-touch-icon",href:"/icon_180x180.png"}),(0,d.jsx)("link",{rel:"mask-icon",href:ct,color:"#465e69"}),(0,d.jsx)("meta",{name:"msapplication-TileImage",content:"/icon_150x150.png"}),(0,d.jsx)("meta",{name:"msapplication-TileColor",content:"#465e69"})]}),(0,d.jsx)("div",{className:"site__header",children:(0,d.jsx)(V,{pathname:t.pathname,hash:t.hash,toggleSidebar:a,links:[{content:"Documentation",url:"/concepts/",isactive:(e,t)=>/^\/(api|concepts|configuration|guides|loaders|migrate|plugins)/.test(t.pathname),children:c(p.filter((e=>{let{name:t}=e;return!1===k.includes(t)})))},{content:"Contribute",url:"/contribute/"},{content:"Blog",url:"/blog/"}]})}),b()?(0,d.jsx)(Z,{isOpen:n,sections:c(ut.children),toggle:a}):null,(0,d.jsxs)(s.Z5,{children:[(0,d.jsx)(s.AW,{index:!0,element:(0,d.jsx)(he,{})}),(0,d.jsxs)(s.AW,{element:(0,d.jsx)(Y,{className:"site__content",children:(0,d.jsx)(s.j3,{})}),children:[(0,d.jsx)(s.AW,{path:"app-shell",element:(0,d.jsx)(r.Fragment,{})}),v.map((i=>{let l=i.path.replace("src/content/","");const{previous:n,next:o}=function(e,t,i="url"){let l,n;const s=e.findIndex((e=>e[i]===t[i]));return-1!==s&&(l=e[s-1],n=e[s+1]),{previous:l,next:n}}(x,i,"url");return(0,d.jsx)(s.AW,{path:i.url,element:(0,d.jsx)(vt,{currentPage:t.pathname,sidebarPages:x,page:i,next:o,previous:n,import:e.import,path:l})},i.url)})),(0,d.jsx)(s.AW,{path:"*",element:(0,d.jsx)(lt,{})})]})]}),(0,d.jsx)(We,{}),(0,d.jsx)(f.ZP,{})]})})}ht.propTypes={import:a().func};var gt=ht;function vt(e){const{currentPage:t,sidebarPages:i,page:l,previous:n,next:s}=e,o=e.import(e.path);return(0,d.jsxs)(r.Fragment,{children:[(0,d.jsx)(be,{}),(0,d.jsx)(Ie,{className:"site__sidebar",currentPage:t,pages:i}),(0,d.jsx)(it,{...l,content:o,previous:n,next:s})]})}function bt(){return(0,d.jsx)(gt,{import:e=>i(7755)(`./${e}`)})}vt.propTypes={currentPage:a().string,sidebarPages:a().array,previous:a().object,next:a().object,page:a().object,import:a().func,path:a().string};const ft=c,xt=l.hydrate;b()&&xt((0,d.jsx)(ft,{id:"UA-46921629-2",children:(0,d.jsx)(rt.B6,{children:(0,d.jsx)(bt,{})})}),document.getElementById("root"))},7338:function(e){const t=void 0!==window&&void 0!==window.document;e.exports=t},833:function(e){e.exports=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];if(0===e.length)return;let t=99;for(const i of e)i.level2&&void 0!==arguments[2]?arguments[2]:l(i);if(0===i.length)return[];if(i.length>0){const s=[];return i.forEach((e=>{e.level===n?s.push([e]):s[s.length-1].push(e)})),s.map((i=>{if(i.length>1){const[n,...s]=i;return{...n,title2:n.title.replace(new RegExp(`^${t}\\.`,"i"),""),children:e(n.title,s,l(s))}}return{...i[0],title2:i[0].title.replace(new RegExp(`^${t}\\.`,"i"),"")}}))}}},7268:function(e){e.exports=function(){const e="localStorageTest";try{localStorage.setItem(e,e),localStorage.removeItem(e)}catch(e){return!1}}},7755:function(e,t,i){var l={"./api/cli.mdx":[8493,8493],"./api/compilation-hooks.mdx":[2433,2433],"./api/compilation-object.mdx":[388,388],"./api/compiler-hooks.mdx":[4951,4951],"./api/contextmodulefactory-hooks.mdx":[9806,9806],"./api/hot-module-replacement.mdx":[1567,1567],"./api/index.mdx":[9317,9317],"./api/loaders.mdx":[5773,5773],"./api/logging.mdx":[8197,8197],"./api/module-methods.mdx":[5229,5229],"./api/module-variables.mdx":[1903,1903],"./api/node.mdx":[1126,1126],"./api/normalmodulefactory-hooks.mdx":[1280,1280],"./api/parser.mdx":[8925,8925],"./api/plugins.mdx":[5389,5389],"./api/resolvers.mdx":[4612,4612],"./api/stats.mdx":[9614,9614],"./api/webpack-dev-server.mdx":[5322,5322],"./awesome-webpack.mdx":[7706,7706],"./blog/2020-10-10-webpack-5-release.mdx":[1701,1701],"./blog/2020-12-08-roadmap-2021.mdx":[6638,6638],"./blog/index.mdx":[4616,4616],"./branding.mdx":[9966,9966],"./comparison.mdx":[869,869],"./concepts/configuration.mdx":[345,345],"./concepts/dependency-graph.mdx":[7154,7154],"./concepts/entry-points.mdx":[8597,8597],"./concepts/hot-module-replacement.mdx":[158,158],"./concepts/index.mdx":[7081,7081],"./concepts/loaders.mdx":[8509,8509],"./concepts/manifest.mdx":[5485,5485],"./concepts/module-federation.mdx":[7750,7750],"./concepts/module-resolution.mdx":[1721,1721],"./concepts/modules.mdx":[3662,3662],"./concepts/output.mdx":[4401,4401],"./concepts/plugins.mdx":[6611,6611],"./concepts/targets.mdx":[2395,2395],"./concepts/under-the-hood.mdx":[2437,2437],"./concepts/why-webpack.mdx":[1454,1454],"./configuration/cache.mdx":[6822,6822],"./configuration/configuration-languages.mdx":[4673,4673],"./configuration/configuration-types.mdx":[7801,2068],"./configuration/dev-server.mdx":[6415,6415],"./configuration/devtool.mdx":[7474,7474],"./configuration/entry-context.mdx":[9003,9003],"./configuration/experiments.mdx":[734,734],"./configuration/extending-configurations.mdx":[6965,6965],"./configuration/externals.mdx":[5030,5030],"./configuration/index.mdx":[5902,5902],"./configuration/mode.mdx":[4928,4928],"./configuration/module.mdx":[4409,4409],"./configuration/node.mdx":[1789,1789],"./configuration/optimization.mdx":[8624,8624],"./configuration/other-options.mdx":[8641,8641],"./configuration/output.mdx":[5687,5687],"./configuration/performance.mdx":[9662,9662],"./configuration/plugins.mdx":[2562,2562],"./configuration/resolve.mdx":[7067,7067],"./configuration/stats.mdx":[22,22],"./configuration/target.mdx":[1286,1286],"./configuration/watch.mdx":[2459,2459],"./contribute/debugging.mdx":[4592,4592],"./contribute/index.mdx":[6949,6949],"./contribute/plugin-patterns.mdx":[2699,2699],"./contribute/release-process.mdx":[4385,4385],"./contribute/writers-guide.mdx":[8301,8301],"./contribute/writing-a-loader.mdx":[242,242],"./contribute/writing-a-plugin.mdx":[1227,1227],"./glossary.mdx":[7940,7940],"./guides/asset-management.mdx":[9097,9097],"./guides/asset-modules.mdx":[6295,6295],"./guides/author-libraries.mdx":[783,783],"./guides/build-performance.mdx":[6231,6231],"./guides/caching.mdx":[2570,2570],"./guides/code-splitting.mdx":[596,596],"./guides/csp.mdx":[3139,3139],"./guides/dependency-management.mdx":[3529,3529],"./guides/development-vagrant.mdx":[3575,3575],"./guides/development.mdx":[6945,6945],"./guides/ecma-script-modules.mdx":[9744,9744],"./guides/entry-advanced.mdx":[2715,2715],"./guides/environment-variables.mdx":[1955,1955],"./guides/getting-started.mdx":[4364,4364],"./guides/hot-module-replacement.mdx":[5554,5554],"./guides/index.mdx":[3295,3295],"./guides/installation.mdx":[8972,8972],"./guides/integrations.mdx":[3849,3849],"./guides/lazy-loading.mdx":[6002,6002],"./guides/output-management.mdx":[5592,5592],"./guides/package-exports.mdx":[1853,1853],"./guides/production.mdx":[3510,3510],"./guides/progressive-web-application.mdx":[1062,1062],"./guides/public-path.mdx":[3781,3781],"./guides/shimming.mdx":[8937,8937],"./guides/tree-shaking.mdx":[9970,9970],"./guides/typescript.mdx":[4168,4168],"./guides/web-workers.mdx":[6006,6006],"./index.mdx":[1975],"./license.mdx":[7047,7047],"./loaders/_babel-loader.mdx":[8321,8321],"./loaders/_coffee-loader.mdx":[1576,1576],"./loaders/_css-loader.mdx":[1736,1736],"./loaders/_exports-loader.mdx":[1693,1693],"./loaders/_expose-loader.mdx":[9922,9922],"./loaders/_html-loader.mdx":[6364,6364],"./loaders/_imports-loader.mdx":[5052,5052],"./loaders/_less-loader.mdx":[5779,5779],"./loaders/_node-loader.mdx":[86,86],"./loaders/_postcss-loader.mdx":[1665,1665],"./loaders/_remark-loader.mdx":[6393,6393],"./loaders/_sass-loader.mdx":[2154,2154],"./loaders/_source-map-loader.mdx":[9749,9749],"./loaders/_style-loader.mdx":[8365,8365],"./loaders/_stylus-loader.mdx":[2537,7801],"./loaders/_thread-loader.mdx":[1880,1880],"./loaders/_val-loader.mdx":[7203,7203],"./loaders/index.mdx":[7695,7695],"./migrate/3.mdx":[3807,3807],"./migrate/4.mdx":[9470,9470],"./migrate/5.mdx":[5521,5521],"./migrate/index.mdx":[9412,9412],"./plugins/NoEmitOnErrorsPlugin.mdx":[3311,3311],"./plugins/_compression-webpack-plugin.mdx":[3557,3557],"./plugins/_copy-webpack-plugin.mdx":[2027,2027],"./plugins/_css-minimizer-webpack-plugin.mdx":[4489,4489],"./plugins/_eslint-webpack-plugin.mdx":[482,482],"./plugins/_html-minimizer-webpack-plugin.mdx":[436,436],"./plugins/_image-minimizer-webpack-plugin.mdx":[5084,5084],"./plugins/_install-webpack-plugin.mdx":[5586,5586],"./plugins/_json-minimizer-webpack-plugin.mdx":[9439,9439],"./plugins/_mini-css-extract-plugin.mdx":[6640,6640],"./plugins/_stylelint-webpack-plugin.mdx":[7140,7140],"./plugins/_svg-chunk-webpack-plugin.mdx":[7636,7636],"./plugins/_terser-webpack-plugin.mdx":[1883,1883],"./plugins/automatic-prefetch-plugin.mdx":[1710,1710],"./plugins/banner-plugin.mdx":[7036,7036],"./plugins/commons-chunk-plugin.mdx":[4914,4914],"./plugins/context-exclusion-plugin.mdx":[8832,8832],"./plugins/context-replacement-plugin.mdx":[4212,4212],"./plugins/define-plugin.mdx":[1417,1417],"./plugins/dll-plugin.mdx":[5990,5990],"./plugins/environment-plugin.mdx":[7224,7224],"./plugins/eval-source-map-dev-tool-plugin.mdx":[4628,4628],"./plugins/hashed-module-ids-plugin.mdx":[486,486],"./plugins/hot-module-replacement-plugin.mdx":[2098,2098],"./plugins/html-webpack-plugin.mdx":[6852,6852],"./plugins/ignore-plugin.mdx":[38,38],"./plugins/index.mdx":[4866,4866],"./plugins/internal-plugins.mdx":[8178,8178],"./plugins/limit-chunk-count-plugin.mdx":[8366,8366],"./plugins/min-chunk-size-plugin.mdx":[9925,9925],"./plugins/module-concatenation-plugin.mdx":[2760,2760],"./plugins/module-federation-plugin.mdx":[2877,2877],"./plugins/normal-module-replacement-plugin.mdx":[2338,2338],"./plugins/prefetch-plugin.mdx":[3191,3191],"./plugins/profiling-plugin.mdx":[2355,2355],"./plugins/progress-plugin.mdx":[7849,7849],"./plugins/provide-plugin.mdx":[672,672],"./plugins/source-map-dev-tool-plugin.mdx":[7684,7684],"./plugins/split-chunks-plugin.mdx":[9529,9529],"./plugins/watch-ignore-plugin.mdx":[8664,8664]};function n(e){if(!i.o(l,e))return Promise.resolve().then((function(){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}));var t=l[e],n=t[0];return Promise.all(t.slice(1).map(i.e)).then((function(){return i(n)}))}n.keys=function(){return Object.keys(l)},n.id=7755,e.exports=n},2807:function(e,t,i){"use strict";e.exports=i.p+"icon-square-small-slack.1c7f4f7a52c41f94.png"}},s={};function o(e){var t=s[e];if(void 0!==t)return t.exports;var i=s[e]={id:e,loaded:!1,exports:{}};return n[e].call(i.exports,i,i.exports,o),i.loaded=!0,i.exports}o.m=n,e=[],o.O=function(t,i,l,n){if(!i){var s=1/0;for(c=0;c=n)&&Object.keys(o.O).every((function(e){return o.O[e](i[r])}))?i.splice(r--,1):(a=!1,n0&&e[c-1][2]>n;c--)e[c]=e[c-1];e[c]=[i,l,n]},o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,{a:t}),t},i=Object.getPrototypeOf?function(e){return Object.getPrototypeOf(e)}:function(e){return e.__proto__},o.t=function(e,l){if(1&l&&(e=this(e)),8&l)return e;if("object"==typeof e&&e){if(4&l&&e.__esModule)return e;if(16&l&&"function"==typeof e.then)return e}var n=Object.create(null);o.r(n);var s={};t=t||[null,i({}),i([]),i(i)];for(var a=2&l&&e;"object"==typeof a&&!~t.indexOf(a);a=i(a))Object.getOwnPropertyNames(a).forEach((function(t){s[t]=function(){return e[t]}}));return s.default=function(){return e},o.d(n,s),n},o.d=function(e,t){for(var i in t)o.o(t,i)&&!o.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},o.f={},o.e=function(e){return Promise.all(Object.keys(o.f).reduce((function(t,i){return o.f[i](e,t),t}),[]))},o.u=function(e){return e+"."+{22:"0bad52954cb1e535",38:"e41ef84c9f39a001",86:"798417f717f86ccf",158:"d3a8b05ab5eba34f",242:"ab10ab7c1dd76981",345:"9125a841e4d2a69b",388:"5e365f623a577b20",436:"effec7f1a6cd3f7c",482:"fb2f5c5690f2ede6",486:"07eea4c8e398ceaa",596:"de1fc8e89d1d0054",672:"33a05dec2644a3f2",734:"ef3ca96602fb1b36",783:"744dc2e0dbfa8f1e",869:"061b7b19fe192d7c",1062:"4b4a6442fe45bf9b",1126:"34ecbee20d75652e",1227:"4dd7e385946056e3",1280:"ca77f17769a1fe4e",1286:"5649293f903c744c",1360:"6cad8579fd1cadcd",1417:"2f8c67acd805e5a3",1454:"5a7c23e574f94322",1567:"ad0b41ed522166c6",1576:"41232090156c81b9",1665:"d8663b24781bbe67",1693:"52992d55c841c5b1",1701:"75a769d0d5bf3a68",1710:"a08b5eff539700ec",1721:"61e09c64706ccef2",1736:"3d5a6c937c98715e",1789:"43aeeae7733fb125",1853:"69cc4fcf0e934cda",1880:"6af612be186164fe",1883:"f4fbb18529b11868",1903:"82d0b4480a2c5038",1955:"4ca3f15610c41345",2027:"aa99215ab333639a",2068:"d8a07ebf1384b11f",2098:"4086d0614deb4bc3",2154:"0dfc8e89172c5e31",2338:"5125ff1542976e5b",2355:"e1aff2153b6603bb",2395:"1cc5a97825b30d7f",2433:"88ab42f4c72e9006",2437:"fde06a90084b2261",2459:"3d07df3f3b01a989",2562:"595a91fb8b0a83de",2570:"d7aaf2065d6061c3",2699:"9f054a024abea74b",2715:"4a78aad947bc8977",2760:"037d501d9f73c652",2877:"dae4e947f31ce809",3139:"4939482d29098ec4",3191:"82222249a6d51ee7",3295:"b887ad5c2e6198b9",3311:"d31770cad34ad2b8",3510:"1bb43fc88b3af023",3529:"ac8397f3631880f8",3557:"28ebc20129af05e8",3575:"13be42be98092ab4",3662:"01f120a0e9e04079",3781:"5270273165b136a8",3790:"5aaebcd7904c4130",3807:"b4ab89f55293feb9",3849:"b5b1078e8a6dbeea",4168:"cfbd5f90cc1a94c6",4212:"4a1cf37925dc91a3",4364:"2ec88ef1909289d9",4385:"c34e4ad461fdf005",4401:"602150ffe8747c75",4409:"7f309035adca33d9",4483:"b1dca0f86fb6b94a",4489:"d3832bba2c66c356",4592:"6aeb081ccbb7ad57",4612:"8c1244ae60e18043",4616:"18b505e4af620fdc",4628:"4a8df0149fa05674",4673:"ec17bf95d78ebe18",4866:"4a718a184bcdfb92",4914:"c30644d140a43cbf",4928:"4fac0a28d6febcdb",4951:"16978b849492c379",5030:"236972df8300dd08",5052:"dbaf5d7045d265e6",5084:"5697db566cee5aa8",5229:"0d9537c0b4424333",5322:"0e90c6d4e053509b",5389:"cccfd28e4c273336",5485:"8e7d453fdd3b839f",5521:"07f7edf67512dc6d",5554:"1fcfe31e22986204",5586:"11d9359dd74f5bdb",5592:"b0adab98810c0d97",5687:"f2fc5dd6dfcf9833",5773:"97779938b1cff19f",5779:"7dc2b73a690b3412",5902:"04710a0dd0dcc3ff",5990:"42fbea7ab2dd9537",6002:"8211e0cac546c008",6006:"b7e767f261aee1a9",6231:"e2cdde7213fd2271",6295:"bb4384df0fcba912",6364:"3ba9b11d6aed95f8",6393:"8be4b93597db826d",6415:"1d6e9d7c6f2615cf",6611:"f2a46b9cba680306",6638:"9c9636b4b7d069d8",6640:"b07704d9b272e1bc",6822:"a57cf61b6d0ffa1c",6852:"289a8c22b4857b2e",6945:"f1381c0b67a31547",6949:"bd404ee97e767c23",6965:"ef365dbc467507f8",7036:"375bb82829f91c11",7047:"396bef6aeb691c24",7067:"cb268bf99e1d99c4",7081:"5d74d5f525540796",7140:"43b99f9d9d019e60",7154:"f3ac387c19d800ee",7203:"8477f497f03de2c8",7224:"dfc04cf727de379a",7474:"f14d060f3e66f6fb",7636:"5b8ba386984e86d2",7684:"0c3f12933a0a746e",7695:"7b8750dbd0d81343",7706:"2cfc624922dd8e66",7750:"58576bd4203f2689",7801:"77dfea958490e14b",7849:"529ea11328581b55",7940:"93c658c9deeceacb",8178:"8880dd2787c1a656",8197:"f6c60f1fed359f4a",8301:"344706718b004ad8",8321:"c69085786c3a7fe3",8365:"35824892b9c4f79d",8366:"f1059a2785a4de8f",8493:"2d23a16998fc39b9",8509:"3681f6241da34855",8597:"20a72d6a3a9ee9b3",8624:"f8782d181726ba5e",8641:"06404db7c93760fa",8664:"d82df2bf521b320f",8832:"dd20a5ea95dacc98",8925:"8b996e4929f27ed5",8937:"0d7393e8b9338a00",8972:"80e3e466fef72ff7",9003:"31e799b11f09c97f",9097:"4e23fe8af21a373b",9317:"325355a99ad4b972",9412:"ac6e0846a1cc4438",9439:"c7e32579484000dc",9470:"f5b29d01261f171e",9514:"686c191d57965d19",9529:"db2b83f6aa465582",9614:"3ccf1fe3507c30fc",9662:"80294093518d02d4",9744:"157f51ec0a90a90a",9749:"c116f75e510ae890",9806:"cd32286980ff579a",9922:"589d0aa47821100e",9925:"1d9ff238b2beb027",9966:"3e32335fe844f02f",9970:"4312ad51b3195ba8"}[e]+".js"},o.miniCssF=function(e){return e+".aa5e42b4ace15744.css"},o.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},l={},o.l=function(e,t,i,n){if(l[e])l[e].push(t);else{var s,a;if(void 0!==i)for(var r=document.getElementsByTagName("script"),d=0;d<scriptsrc="dist/bundle.js"></script></body>
-</html>
Then run webpack on the command-line to create bundle.js.
Awesome isn't it? Let's dive in!
Get Started quickly in our Guides section, or dig into the Concepts section for more high-level information on the core notions behind webpack.
Support the Team
Through contributions, donations, and sponsorship, you allow webpack to thrive. Your donations directly support office hours, continued enhancements, and most importantly, great documentation and learning material!
Latest Sponsors
Platinum Sponsors
Gold Sponsors
Silver Sponsors
Bronze Sponsors
Backers
\ No newline at end of file
+</html>
Then run webpack on the command-line to create bundle.js.
Awesome isn't it? Let's dive in!
Get Started quickly in our Guides section, or dig into the Concepts section for more high-level information on the core notions behind webpack.
Support the Team
Through contributions, donations, and sponsorship, you allow webpack to thrive. Your donations directly support office hours, continued enhancements, and most importantly, great documentation and learning material!
Latest Sponsors
Platinum Sponsors
Gold Sponsors
Silver Sponsors
Bronze Sponsors
Backers
\ No newline at end of file
diff --git a/license/index.html b/license/index.html
index 85e24316b26f..3fd85dfd1ed0 100644
--- a/license/index.html
+++ b/license/index.html
@@ -1,2 +1,2 @@
License | webpack
\ No newline at end of file
diff --git a/loaders/babel-loader/index.html b/loaders/babel-loader/index.html
index 24a212ae16ea..376631871b27 100644
--- a/loaders/babel-loader/index.html
+++ b/loaders/babel-loader/index.html
@@ -197,4 +197,4 @@
}};
\ No newline at end of file
diff --git a/loaders/coffee-loader/index.html b/loaders/coffee-loader/index.html
index da061becfba6..f4676679f7ae 100644
--- a/loaders/coffee-loader/index.html
+++ b/loaders/coffee-loader/index.html
@@ -90,4 +90,4 @@
},],},
-};
Contributing
Please take a moment to read our contributing guidelines if you haven't yet done so.
\ No newline at end of file
diff --git a/loaders/exports-loader/index.html b/loaders/exports-loader/index.html
index 4229c66fb953..4fe718d18ed8 100644
--- a/loaders/exports-loader/index.html
+++ b/loaders/exports-loader/index.html
@@ -325,4 +325,4 @@
// Code// ...
-export{ Foo as FooA, Bar, Baz };
Contributing
Please take a moment to read our contributing guidelines if you haven't yet done so.
\ No newline at end of file
diff --git a/loaders/expose-loader/index.html b/loaders/expose-loader/index.html
index 7d63b7aec29a..26757a1f03a8 100644
--- a/loaders/expose-loader/index.html
+++ b/loaders/expose-loader/index.html
@@ -162,4 +162,4 @@
},],},
-};
Contributing
Please take a moment to read our contributing guidelines if you haven't yet done so.
\ No newline at end of file
diff --git a/loaders/html-loader/index.html b/loaders/html-loader/index.html
index 0d70b9aa21f4..b11da6d6999c 100644
--- a/loaders/html-loader/index.html
+++ b/loaders/html-loader/index.html
@@ -619,4 +619,4 @@
},],},
-};
Contributing
Please take a moment to read our contributing guidelines if you haven't yet done so.
\ No newline at end of file
diff --git a/loaders/index.html b/loaders/index.html
index 12c56d6ee8cb..8a014fe3ab5c 100644
--- a/loaders/index.html
+++ b/loaders/index.html
@@ -1 +1 @@
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/loaders/less-loader/index.html b/loaders/less-loader/index.html
index 087c6218d183..dccd1f0854a8 100644
--- a/loaders/less-loader/index.html
+++ b/loaders/less-loader/index.html
@@ -341,4 +341,4 @@
return Math.PI;});},
-};
Extracting style sheets
Bundling CSS with webpack has some nice advantages like referencing images and fonts with hashed urls or hot module replacement in development. In production, on the other hand, it's not a good idea to apply your style sheets depending on JS execution. Rendering may be delayed or even a FOUC might be visible. Thus it's often still better to have them as separate files in your final production build.
There are two possibilities to extract a style sheet from the bundle:
extract-loader (simpler, but specialized on the css-loader's output)
Bundling CSS with webpack has some nice advantages like referencing images and fonts with hashed urls or hot module replacement in development. In production, on the other hand, it's not a good idea to apply your style sheets depending on JS execution. Rendering may be delayed or even a FOUC might be visible. Thus it's often still better to have them as separate files in your final production build.
There are two possibilities to extract a style sheet from the bundle:
extract-loader (simpler, but specialized on the css-loader's output)
\ No newline at end of file
diff --git a/loaders/node-loader/index.html b/loaders/node-loader/index.html
index 1b044f2fbe9b..b9a994ff33ba 100644
--- a/loaders/node-loader/index.html
+++ b/loaders/node-loader/index.html
@@ -94,4 +94,4 @@
},],},
-};
Contributing
Please take a moment to read our contributing guidelines if you haven't yet done so.
\ No newline at end of file
diff --git a/loaders/remark-loader/index.html b/loaders/remark-loader/index.html
index e6c40011ea75..3d8d498f8626 100644
--- a/loaders/remark-loader/index.html
+++ b/loaders/remark-loader/index.html
@@ -202,4 +202,4 @@
},],},
-};
Contributing
Please take a moment to read our contributing guidelines if you haven't yet done so.
\ No newline at end of file
diff --git a/loaders/sass-loader/index.html b/loaders/sass-loader/index.html
index 43ea196ed09d..35072c3543fe 100644
--- a/loaders/sass-loader/index.html
+++ b/loaders/sass-loader/index.html
@@ -482,4 +482,4 @@
},],},
-};
\ No newline at end of file
diff --git a/loaders/source-map-loader/index.html b/loaders/source-map-loader/index.html
index f011587eb6c4..a4753f7aa4a9 100644
--- a/loaders/source-map-loader/index.html
+++ b/loaders/source-map-loader/index.html
@@ -61,4 +61,4 @@
],},
ignoreWarnings:[/Failed to parse source map/],
-};
More information about the ignoreWarnings option can be found here
Contributing
Please take a moment to read our contributing guidelines if you haven't yet done so.
\ No newline at end of file
diff --git a/loaders/stylus-loader/index.html b/loaders/stylus-loader/index.html
index 40f960a7606b..74c5bc464d08 100644
--- a/loaders/stylus-loader/index.html
+++ b/loaders/stylus-loader/index.html
@@ -465,4 +465,4 @@
},],},
-};
Extracting style sheets
Bundling CSS with webpack has some nice advantages like referencing images and fonts with hashed urls or hot module replacement in development. In production, on the other hand, it's not a good idea to apply your style sheets depending on JS execution. Rendering may be delayed or even a FOUC might be visible. Thus it's often still better to have them as separate files in your final production build.
There are two possibilities to extract a style sheet from the bundle:
extract-loader (simpler, but specialized on the css-loader's output)
Bundling CSS with webpack has some nice advantages like referencing images and fonts with hashed urls or hot module replacement in development. In production, on the other hand, it's not a good idea to apply your style sheets depending on JS execution. Rendering may be delayed or even a FOUC might be visible. Thus it's often still better to have them as separate files in your final production build.
There are two possibilities to extract a style sheet from the bundle:
extract-loader (simpler, but specialized on the css-loader's output)
\ No newline at end of file
diff --git a/loaders/thread-loader/index.html b/loaders/thread-loader/index.html
index 8ea19f407c9c..1740882b2396 100644
--- a/loaders/thread-loader/index.html
+++ b/loaders/thread-loader/index.html
@@ -67,4 +67,4 @@
'babel-preset-es2015','sass-loader',]
-);
Contributing
Please take a moment to read our contributing guidelines if you haven't yet done so.
\ No newline at end of file
diff --git a/loaders/val-loader/index.html b/loaders/val-loader/index.html
index 86a29338917a..5c50bc31457b 100644
--- a/loaders/val-loader/index.html
+++ b/loaders/val-loader/index.html
@@ -194,4 +194,4 @@
},],},
-};
Contributing
Please take a moment to read our contributing guidelines if you haven't yet done so.
\ No newline at end of file
diff --git a/migrate/5/index.html b/migrate/5/index.html
index 63429fbf8096..376a5c84a8b4 100644
--- a/migrate/5/index.html
+++ b/migrate/5/index.html
@@ -18,4 +18,4 @@
]}
If you were using WebAssembly via import, you should follow this two step process:
Enable the deprecated spec by setting experiments.syncWebAssembly: true, to get the same behavior as in webpack 4.
After successful migration to webpack 5, change the experiments value to experiments: { asyncWebAssembly: true } to use the up-to-date spec for WASM integration.
Reconsider optimization.splitChunks:
It's recommended to use either the defaults or optimization.splitChunks: { chunks: 'all' }.
When using a custom configuration, drop name: false and replace name: string | function with idHint: string | function.
It was possible to turn off the defaults by setting optimization.splitChunks.cacheGroups: { default: false, vendors: false }. We don't recommend doing this, but if you really want to get the same effect in webpack 5: optimization.splitChunks.cacheGroups: { default: false, defaultVendors: false }.
Consider removing defaults:
Using entry: './src/index.js': you can omit it, that's the default.
Using output.path: path.resolve(__dirname, 'dist'): you can omit it, that's the default.
Using output.filename: '[name].js': you can omit it, that's the default.
Need to support an older browser like IE 11?
If you have browserslist enabled for your project, webpack 5 will reuse your browserslist config to decide which code style to emit for the runtime code.
Make sure to:
set target to browserslist or remove target letting webpack set browserslist automatically for you.
add a IE 11 to your browserslist configuration.
Without a browserslist webpack's runtime code uses ES2015 syntax (e.g., arrow function) to build smaller bundles. Hence you'll need to set target: ['web', 'es5'] to use the ES5 syntax for browsers (like IE11) which don't support ES2015 syntax .
For Node.js, builds include the supported Node.js version in the target option and webpack will automatically figure out which syntax is supported, e.g. target: 'node8.6'.
Cleanup the code
Using /* webpackChunkName: '...' */
Make sure to understand the intention:
The chunk's name here is intended to be public.
It's not a development-only name.
Webpack will use it to name files in production and development modes.
Webpack 5 will automatically assign useful file names in development mode even when not using webpackChunkName.
Using named exports from JSON modules
This is not supported by the new specification and you will get a warning. Instead of:
import{ version }from'./package.json';
console.log(version);
When using const compiler = webpack(...);, make sure to close the compiler after using it: compiler.close(callback);.
This doesn't apply to the webpack(..., callback) form which automatically closes.
This is optional if you use webpack in watching mode until the user ends the process. The idle phases in watch mode will be used for this kind of work.
Run a single build and follow advice
Please make sure to read the building errors/warnings carefully. If there is no corresponding advice, please create an issue and we will try to resolve it.
Repeat the following steps until you solved at least level 3 or 4:
Level 1: Schema validation fails.
Configuration options have changed. There should be a validation error with a BREAKING CHANGE: note, or a hint of which option should be used instead.
Level 2: Webpack exits with an error.
The error message should tell you what needs to be changed.
Level 3: Build Errors.
The error message should have a BREAKING CHANGE: note.
Level 4: Build Warnings.
The warning message should tell you what can be improved.
Level 5: Runtime Errors.
This is tricky. You probably have to debug to find the problem. General advice is difficult here. But we do list some common advice below regarding Runtime Errors:
process is not defined.
webpack 5 does no longer include a polyfill for this Node.js variable. Avoid using it in the frontend code.
Want to support browser usage? Use the exports or imports package.json field to use different code depending on the environment.
Also use the browser field to support older bundlers.
Alternative: Wrap code blocks with the typeof process checks. Note that this will have a negative impact on the bundle size.
Want to use environment variables with process.env.VARIABLE? You need to use the DefinePlugin or EnvironmentPlugin to define these variables in the configuration.
Consider using VARIABLE instead and make sure to check typeof VARIABLE !== 'undefined' too. process.env is Node.js specific and should be avoided in frontend code.
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.
Level 6: Deprecation Warnings.
You probably get a lot of deprecation warnings. This is not directly a problem. Plugins need time to catch up with core changes. Please report these deprecations to the plugins. These deprecations are only warnings and the build will still work with only minor drawbacks (like less performance).
You can hide deprecation warnings by running node with --no-deprecation flag, e.g.: node --no-deprecation node_modules/webpack/bin/webpack.js. This should only be a temporary workaround.
Plugins and Loaders contributors can follow the advice in the deprecation messages to improve the code.
Level 7: Performance issues.
Usually, performance should improve with webpack 5, but there are also a few cases where performance gets worse.
And here are something you can do to improve the situation:
Profile where the time is spent.
--profile --progress displays a simple performance profile now
You can save these profiles to files and provide them in issues.
Try using --no-turbo-inlining flag for better stack traces in some cases.
Time for building modules in incremental builds can be improved by reverting to unsafe caching like in webpack 4:
module.unsafeCache: true
But this might affect the ability to handle some of the changes to the code base
Full build
Backward-compatibility layer for the deprecated features will usually have worse performance compared to the new features.
Creating many warnings can affect build performance, even if they are ignored.
Source Maps are expensive. Check devtool option in the documentation to see a comparison of the different options.
Anti-Virus protection might affect performance of the file system access.
Persistent Caching can help to improve the repetitive full builds.
Module Federation allows to split the application into multiple smaller builds.
Everything works?
Please tweet that you have successfully migrated to webpack 5. Tweet it
It is not working?
Create an issue and tell us about the issues you have encountered during the migration.
Something missing in this guide?
Please open a Pull Request to help the next person using this guide.
Changes to internals
The changes to webpack internals such as: adding types, refactoring code and methods renaming are listed here for anyone interested. But they are not intended as a part of common use-case migration.
Module.nameForCondition, Module.updateCacheModule and Module.chunkCondition are no longer optional.
getOptions method for Loaders
Webpack 5 ships with built-in this.getOptions method available in loader context. This is a breaking change for loaders that had been using getOptions method from previously preferred schema-utils:
this.getOptions is available since webpack 5
Instead of JSON5 it supports JSON as a query string: ?{arg:true} → ?{"arg":true}. Using JSON5 should be considered and documented as deprecated in favor of JSON in the respective Loader's documentation.
loader-utils has specific behavior for parsing query strings (true, false and null won't be parsed as string but as a primitive value). This is no longer the case for the new built-in this.getOptions method, which uses native querystring parsing (ships with Node.js). It is still possible to add custom behavior for these cases in the Loader's code after getting the options by using this.getOptions method.
Schema argument is optional for the new this.getOptions method, but we strongly advise to add schema validation for your Loader's options. The title field in the schema, can be used to customize the validation error message e.g. "title": "My Loader ooooptions" will result in displaying errors this way: Invalid ooooptions object. My Loader has been initialised using an ooooptions object that does not match the API schema. - ooooptions.foo.bar.baz should be a string.
\ No newline at end of file
+console.log(pkg.version);
Cleanup the build code
When using const compiler = webpack(...);, make sure to close the compiler after using it: compiler.close(callback);.
This doesn't apply to the webpack(..., callback) form which automatically closes.
This is optional if you use webpack in watching mode until the user ends the process. The idle phases in watch mode will be used for this kind of work.
Run a single build and follow advice
Please make sure to read the building errors/warnings carefully. If there is no corresponding advice, please create an issue and we will try to resolve it.
Repeat the following steps until you solved at least level 3 or 4:
Level 1: Schema validation fails.
Configuration options have changed. There should be a validation error with a BREAKING CHANGE: note, or a hint of which option should be used instead.
Level 2: Webpack exits with an error.
The error message should tell you what needs to be changed.
Level 3: Build Errors.
The error message should have a BREAKING CHANGE: note.
Level 4: Build Warnings.
The warning message should tell you what can be improved.
Level 5: Runtime Errors.
This is tricky. You probably have to debug to find the problem. General advice is difficult here. But we do list some common advice below regarding Runtime Errors:
process is not defined.
webpack 5 does no longer include a polyfill for this Node.js variable. Avoid using it in the frontend code.
Want to support browser usage? Use the exports or imports package.json field to use different code depending on the environment.
Also use the browser field to support older bundlers.
Alternative: Wrap code blocks with the typeof process checks. Note that this will have a negative impact on the bundle size.
Want to use environment variables with process.env.VARIABLE? You need to use the DefinePlugin or EnvironmentPlugin to define these variables in the configuration.
Consider using VARIABLE instead and make sure to check typeof VARIABLE !== 'undefined' too. process.env is Node.js specific and should be avoided in frontend code.
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.
Level 6: Deprecation Warnings.
You probably get a lot of deprecation warnings. This is not directly a problem. Plugins need time to catch up with core changes. Please report these deprecations to the plugins. These deprecations are only warnings and the build will still work with only minor drawbacks (like less performance).
You can hide deprecation warnings by running node with --no-deprecation flag, e.g.: node --no-deprecation node_modules/webpack/bin/webpack.js. This should only be a temporary workaround.
Plugins and Loaders contributors can follow the advice in the deprecation messages to improve the code.
Level 7: Performance issues.
Usually, performance should improve with webpack 5, but there are also a few cases where performance gets worse.
And here are something you can do to improve the situation:
Profile where the time is spent.
--profile --progress displays a simple performance profile now
You can save these profiles to files and provide them in issues.
Try using --no-turbo-inlining flag for better stack traces in some cases.
Time for building modules in incremental builds can be improved by reverting to unsafe caching like in webpack 4:
module.unsafeCache: true
But this might affect the ability to handle some of the changes to the code base
Full build
Backward-compatibility layer for the deprecated features will usually have worse performance compared to the new features.
Creating many warnings can affect build performance, even if they are ignored.
Source Maps are expensive. Check devtool option in the documentation to see a comparison of the different options.
Anti-Virus protection might affect performance of the file system access.
Persistent Caching can help to improve the repetitive full builds.
Module Federation allows to split the application into multiple smaller builds.
Everything works?
Please tweet that you have successfully migrated to webpack 5. Tweet it
It is not working?
Create an issue and tell us about the issues you have encountered during the migration.
Something missing in this guide?
Please open a Pull Request to help the next person using this guide.
Changes to internals
The changes to webpack internals such as: adding types, refactoring code and methods renaming are listed here for anyone interested. But they are not intended as a part of common use-case migration.
Module.nameForCondition, Module.updateCacheModule and Module.chunkCondition are no longer optional.
getOptions method for Loaders
Webpack 5 ships with built-in this.getOptions method available in loader context. This is a breaking change for loaders that had been using getOptions method from previously preferred schema-utils:
this.getOptions is available since webpack 5
Instead of JSON5 it supports JSON as a query string: ?{arg:true} → ?{"arg":true}. Using JSON5 should be considered and documented as deprecated in favor of JSON in the respective Loader's documentation.
loader-utils has specific behavior for parsing query strings (true, false and null won't be parsed as string but as a primitive value). This is no longer the case for the new built-in this.getOptions method, which uses native querystring parsing (ships with Node.js). It is still possible to add custom behavior for these cases in the Loader's code after getting the options by using this.getOptions method.
Schema argument is optional for the new this.getOptions method, but we strongly advise to add schema validation for your Loader's options. The title field in the schema, can be used to customize the validation error message e.g. "title": "My Loader ooooptions" will result in displaying errors this way: Invalid ooooptions object. My Loader has been initialised using an ooooptions object that does not match the API schema. - ooooptions.foo.bar.baz should be a string.
\ No newline at end of file
diff --git a/migrate/index.html b/migrate/index.html
index 96b9354bc49e..b7a8f0e0f8a8 100644
--- a/migrate/index.html
+++ b/migrate/index.html
@@ -1 +1 @@
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/plugins/NoEmitOnErrorsPlugin/index.html b/plugins/NoEmitOnErrorsPlugin/index.html
index b64ac065c9bd..2f95f942b09a 100644
--- a/plugins/NoEmitOnErrorsPlugin/index.html
+++ b/plugins/NoEmitOnErrorsPlugin/index.html
@@ -1,3 +1,3 @@
\ No newline at end of file
diff --git a/plugins/automatic-prefetch-plugin/index.html b/plugins/automatic-prefetch-plugin/index.html
index 82218fd34d3a..0503e4145f7c 100644
--- a/plugins/automatic-prefetch-plugin/index.html
+++ b/plugins/automatic-prefetch-plugin/index.html
@@ -1,4 +1,4 @@
\ No newline at end of file
diff --git a/plugins/commons-chunk-plugin/index.html b/plugins/commons-chunk-plugin/index.html
index 4291fb130ab4..4f1fba56de04 100644
--- a/plugins/commons-chunk-plugin/index.html
+++ b/plugins/commons-chunk-plugin/index.html
@@ -122,4 +122,4 @@
name:'manifest',
minChunks:Infinity,}),
-];
\ No newline at end of file
diff --git a/plugins/compression-webpack-plugin/index.html b/plugins/compression-webpack-plugin/index.html
index fad879356ed0..c644591a85db 100644
--- a/plugins/compression-webpack-plugin/index.html
+++ b/plugins/compression-webpack-plugin/index.html
@@ -195,4 +195,4 @@
minRatio:0.8,}),],
-};
Contributing
Please take a moment to read our contributing guidelines if you haven't yet done so.
\ No newline at end of file
diff --git a/plugins/context-exclusion-plugin/index.html b/plugins/context-exclusion-plugin/index.html
index 626ee65e67d8..44322409215e 100644
--- a/plugins/context-exclusion-plugin/index.html
+++ b/plugins/context-exclusion-plugin/index.html
@@ -1,3 +1,3 @@
\ No newline at end of file
diff --git a/plugins/context-replacement-plugin/index.html b/plugins/context-replacement-plugin/index.html
index 2014256f0f30..1d4a05427107 100644
--- a/plugins/context-replacement-plugin/index.html
+++ b/plugins/context-replacement-plugin/index.html
@@ -20,4 +20,4 @@
);
These two parameters can be used together to redirect requests in a more targeted way. The newContentCreateContextMap allows you to map runtime requests to compile requests in the form of an object:
\ No newline at end of file
diff --git a/plugins/copy-webpack-plugin/index.html b/plugins/copy-webpack-plugin/index.html
index 712f7a0ae586..2973943035ab 100644
--- a/plugins/copy-webpack-plugin/index.html
+++ b/plugins/copy-webpack-plugin/index.html
@@ -664,4 +664,4 @@
],}),],
-};
Contributing
Please take a moment to read our contributing guidelines if you haven't yet done so.
\ No newline at end of file
diff --git a/plugins/css-minimizer-webpack-plugin/index.html b/plugins/css-minimizer-webpack-plugin/index.html
index 8a42dff4c7f5..395e7aa964ba 100644
--- a/plugins/css-minimizer-webpack-plugin/index.html
+++ b/plugins/css-minimizer-webpack-plugin/index.html
@@ -314,4 +314,4 @@
}),],},
-};
Contributing
Please take a moment to read our contributing guidelines if you haven't yet done so.
\ No newline at end of file
diff --git a/plugins/environment-plugin/index.html b/plugins/environment-plugin/index.html
index 0d6575770da8..e0557ed5ac06 100644
--- a/plugins/environment-plugin/index.html
+++ b/plugins/environment-plugin/index.html
@@ -37,4 +37,4 @@
S3_API=mysecretkey
newDotenv({
path:'./.env',// Path to .env file (this is the default)
safe:true,// load .env.example (defaults to "false" which does not use dotenv-safe)
-});
\ No newline at end of file
diff --git a/plugins/eslint-webpack-plugin/index.html b/plugins/eslint-webpack-plugin/index.html
index 732b2b69fcbe..e8a288ed10ee 100644
--- a/plugins/eslint-webpack-plugin/index.html
+++ b/plugins/eslint-webpack-plugin/index.html
@@ -38,4 +38,4 @@
|undefined;};
Default: false
Write the output of the errors to a file, for example a checkstyle xml file for use for reporting on Jenkins CI.
The filePath is an absolute path or relative to the webpack config: output.path.
You can pass in a different formatter for the output file,
-if none is passed in the default/configured formatter will be used.
\ No newline at end of file
diff --git a/plugins/eval-source-map-dev-tool-plugin/index.html b/plugins/eval-source-map-dev-tool-plugin/index.html
index ee377eef86ea..0c55469a2876 100644
--- a/plugins/eval-source-map-dev-tool-plugin/index.html
+++ b/plugins/eval-source-map-dev-tool-plugin/index.html
@@ -4,4 +4,4 @@
plugins:[newwebpack.EvalSourceMapDevToolPlugin({})],};
Exclude Vendor Maps
The following code would exclude source maps for any modules in the vendor.js bundle:
\ No newline at end of file
diff --git a/plugins/hot-module-replacement-plugin/index.html b/plugins/hot-module-replacement-plugin/index.html
index 92d1d9e32e79..31c1d96defe1 100644
--- a/plugins/hot-module-replacement-plugin/index.html
+++ b/plugins/hot-module-replacement-plugin/index.html
@@ -1,3 +1,3 @@
\ No newline at end of file
diff --git a/plugins/html-minimizer-webpack-plugin/index.html b/plugins/html-minimizer-webpack-plugin/index.html
index 20161fe40950..e023102a3d76 100644
--- a/plugins/html-minimizer-webpack-plugin/index.html
+++ b/plugins/html-minimizer-webpack-plugin/index.html
@@ -332,4 +332,4 @@
}),],},
-};
You can use multiple HtmlMinimizerPlugin plugins to compress different files with the different minify function.
Contributing
Please take a moment to read our contributing guidelines if you haven't yet done so.
\ No newline at end of file
diff --git a/plugins/html-webpack-plugin/index.html b/plugins/html-webpack-plugin/index.html
index 4baa0b66716c..cfbbac880dc2 100644
--- a/plugins/html-webpack-plugin/index.html
+++ b/plugins/html-webpack-plugin/index.html
@@ -19,4 +19,4 @@
<body><scriptsrc="index_bundle.js"></script></body>
-</html>
If you have multiple webpack entry points, they will all be included with <script> tags in the generated HTML.
If you have any CSS assets in webpack's output (for example, CSS extracted with the MiniCssExtractPlugin) then these will be included with <link> tags in the <head> element of generated HTML.
If you have multiple webpack entry points, they will all be included with <script> tags in the generated HTML.
If you have any CSS assets in webpack's output (for example, CSS extracted with the MiniCssExtractPlugin) then these will be included with <link> tags in the <head> element of generated HTML.
\ No newline at end of file
diff --git a/plugins/ignore-plugin/index.html b/plugins/ignore-plugin/index.html
index ff1d457c4cdd..2bc9cea77a76 100644
--- a/plugins/ignore-plugin/index.html
+++ b/plugins/ignore-plugin/index.html
@@ -6,4 +6,4 @@
});
Example of ignoring Moment Locales
As of moment 2.18, all locales are bundled together with the core library (see this GitHub issue).
The resourceRegExp parameter passed to IgnorePlugin is not tested against the resolved file names or absolute module names being imported or required, but rather against the string passed to require or importwithin the source code where the import is taking place. For example, if you're trying to exclude node_modules/moment/locale/*.js, this won't work:
...your first regexp must match that './locale/' string. The second contextRegExp parameter is then used to select specific directories from where the import took place. The following will cause those locale files to be ignored:
\ No newline at end of file
diff --git a/plugins/index.html b/plugins/index.html
index 1424263be99d..42e6fcc9341d 100644
--- a/plugins/index.html
+++ b/plugins/index.html
@@ -1 +1 @@
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/plugins/install-webpack-plugin/index.html b/plugins/install-webpack-plugin/index.html
index 7c8af330799a..d39e50138b0c 100644
--- a/plugins/install-webpack-plugin/index.html
+++ b/plugins/install-webpack-plugin/index.html
@@ -85,4 +85,4 @@
(e.g. babel-loader, file-loader, etc.)
\ No newline at end of file
diff --git a/plugins/internal-plugins/index.html b/plugins/internal-plugins/index.html
index ca8225bebf3e..7eae3d901b14 100644
--- a/plugins/internal-plugins/index.html
+++ b/plugins/internal-plugins/index.html
@@ -12,4 +12,4 @@
hooks.updateHash.tap('MyPlugin',(content, oldHash)=>{// you can calculate the hash here as you wish});
-});
\ No newline at end of file
diff --git a/plugins/json-minimizer-webpack-plugin/index.html b/plugins/json-minimizer-webpack-plugin/index.html
index 561fa8769f35..eff8ac8cf7a0 100644
--- a/plugins/json-minimizer-webpack-plugin/index.html
+++ b/plugins/json-minimizer-webpack-plugin/index.html
@@ -77,4 +77,4 @@
}),],},
-};
Contributing
Please take a moment to read our contributing guidelines if you haven't yet done so.
\ No newline at end of file
diff --git a/plugins/limit-chunk-count-plugin/index.html b/plugins/limit-chunk-count-plugin/index.html
index 7e57a9422538..31b122b4222a 100644
--- a/plugins/limit-chunk-count-plugin/index.html
+++ b/plugins/limit-chunk-count-plugin/index.html
@@ -8,4 +8,4 @@
maxChunks:5,}),],
-};
minChunkSize
Keeping chunk size above the specified limit is no longer a feature of this plugin. Use MinChunkSizePlugin instead.
Usage via CLI
This plugin and it's options can also be invoked via the CLI:
\ No newline at end of file
diff --git a/plugins/min-chunk-size-plugin/index.html b/plugins/min-chunk-size-plugin/index.html
index 20502703ef3c..8951979da28b 100644
--- a/plugins/min-chunk-size-plugin/index.html
+++ b/plugins/min-chunk-size-plugin/index.html
@@ -1,3 +1,3 @@
\ No newline at end of file
+});
Usage via CLI
This plugin and it's options can also be invoked via the CLI:
\ No newline at end of file
diff --git a/plugins/mini-css-extract-plugin/index.html b/plugins/mini-css-extract-plugin/index.html
index f10591997fbf..48be740d7f2d 100644
--- a/plugins/mini-css-extract-plugin/index.html
+++ b/plugins/mini-css-extract-plugin/index.html
@@ -652,4 +652,4 @@
<body><scriptsrc="./main.js"></script></body>
-</html>
Media Query Plugin
If you'd like to extract the media queries from the extracted CSS (so mobile users don't need to load desktop or tablet specific CSS anymore) you should use one of the following plugins:
If you'd like to extract the media queries from the extracted CSS (so mobile users don't need to load desktop or tablet specific CSS anymore) you should use one of the following plugins:
\ No newline at end of file
diff --git a/plugins/module-federation-plugin/index.html b/plugins/module-federation-plugin/index.html
index dd5b9ac93f6c..4b7be7c7ae9c 100644
--- a/plugins/module-federation-plugin/index.html
+++ b/plugins/module-federation-plugin/index.html
@@ -129,4 +129,4 @@
},}),],
-};
\ No newline at end of file
diff --git a/plugins/normal-module-replacement-plugin/index.html b/plugins/normal-module-replacement-plugin/index.html
index b5afc00280a3..20f1b4464826 100644
--- a/plugins/normal-module-replacement-plugin/index.html
+++ b/plugins/normal-module-replacement-plugin/index.html
@@ -25,4 +25,4 @@
=>'I am version A'
npx webpack --env APP_TARGET=VERSION_B
-=>'I am version B'
\ No newline at end of file
diff --git a/plugins/prefetch-plugin/index.html b/plugins/prefetch-plugin/index.html
index 916dad750b4e..7deea4c11a93 100644
--- a/plugins/prefetch-plugin/index.html
+++ b/plugins/prefetch-plugin/index.html
@@ -1 +1 @@
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/plugins/profiling-plugin/index.html b/plugins/profiling-plugin/index.html
index 5bd6e1f0a526..3ac4aef3c0df 100644
--- a/plugins/profiling-plugin/index.html
+++ b/plugins/profiling-plugin/index.html
@@ -1,3 +1,3 @@
\ No newline at end of file
+});
In order to view the profile file:
Run webpack with ProfilingPlugin.
Go to Chrome, open DevTools, and go to the Performance tab (formerly Timeline).
Drag and drop generated file (events.json by default) into the profiler.
It will then display timeline stats and calls per plugin!
\ No newline at end of file
diff --git a/plugins/progress-plugin/index.html b/plugins/progress-plugin/index.html
index 39a70bffe068..2dc23733540b 100644
--- a/plugins/progress-plugin/index.html
+++ b/plugins/progress-plugin/index.html
@@ -18,4 +18,4 @@
});
webpack.ProgressPlugin.createDefaultHandler
If the default handler of ProgressPlugin does not meet your requirements, you can customize it using the static ProgressPlugin.createDefaultHandler method.
By default, progress percentage is calculated based on built modules count and total modules count: built / total
The total modules count is unknown in advance and changes during the build. This may cause inaccurate progress percentage.
To solve this problem ProgressPlugin caches the last known total modules count and reuses this value on the next build. The first build will warm the cache but the following builds will use and update this value.
We recommend using percentBy: 'entries' setting for projects with multiple configured entry points. Percentage calculation will become more accurate because the amount of entry points is known in advance.
Supported Hooks
The following hooks report progress information to ProgressPlugin.
\ No newline at end of file
+)=>(percentage:number, msg:string,...args:string[])=>void;
Percentage calculation
By default, progress percentage is calculated based on built modules count and total modules count: built / total
The total modules count is unknown in advance and changes during the build. This may cause inaccurate progress percentage.
To solve this problem ProgressPlugin caches the last known total modules count and reuses this value on the next build. The first build will warm the cache but the following builds will use and update this value.
We recommend using percentBy: 'entries' setting for projects with multiple configured entry points. Percentage calculation will become more accurate because the amount of entry points is known in advance.
Supported Hooks
The following hooks report progress information to ProgressPlugin.
\ No newline at end of file
diff --git a/plugins/provide-plugin/index.html b/plugins/provide-plugin/index.html
index 3abb199f960d..f103d735e303 100644
--- a/plugins/provide-plugin/index.html
+++ b/plugins/provide-plugin/index.html
@@ -21,4 +21,4 @@
_map:['lodash','map'],});
\ No newline at end of file
diff --git a/plugins/source-map-dev-tool-plugin/index.html b/plugins/source-map-dev-tool-plugin/index.html
index 281017680eaa..cb1e9606d92b 100644
--- a/plugins/source-map-dev-tool-plugin/index.html
+++ b/plugins/source-map-dev-tool-plugin/index.html
@@ -19,4 +19,4 @@
publicPath:'https://example.com/project/',
fileContext:'public',});
\ No newline at end of file
diff --git a/plugins/split-chunks-plugin/index.html b/plugins/split-chunks-plugin/index.html
index 48f48a7a11d5..76258b3eadd6 100644
--- a/plugins/split-chunks-plugin/index.html
+++ b/plugins/split-chunks-plugin/index.html
@@ -255,4 +255,4 @@
},},},
-};
\ No newline at end of file
diff --git a/plugins/stylelint-webpack-plugin/index.html b/plugins/stylelint-webpack-plugin/index.html
index 24a39b0f071b..fc890a3419c2 100644
--- a/plugins/stylelint-webpack-plugin/index.html
+++ b/plugins/stylelint-webpack-plugin/index.html
@@ -33,4 +33,4 @@
You can pass in a different formatter for the output file, if none is passed in the default/configured formatter will be used.
\ No newline at end of file
diff --git a/plugins/svg-chunk-webpack-plugin/index.html b/plugins/svg-chunk-webpack-plugin/index.html
index e5b911f3dd9c..3bcbd0c83210 100644
--- a/plugins/svg-chunk-webpack-plugin/index.html
+++ b/plugins/svg-chunk-webpack-plugin/index.html
@@ -88,4 +88,4 @@
filename:'[name].[fullhash].svg'})]
-};
License
svg-chunk-webpack-plugin is licensed under the MIT License.
\ No newline at end of file
diff --git a/plugins/terser-webpack-plugin/index.html b/plugins/terser-webpack-plugin/index.html
index 5e2868448bf3..a99f6115a232 100644
--- a/plugins/terser-webpack-plugin/index.html
+++ b/plugins/terser-webpack-plugin/index.html
@@ -510,4 +510,4 @@
}),],},
-};
Contributing
Please take a moment to read our contributing guidelines if you haven't yet done so.
\ No newline at end of file
diff --git a/plugins/watch-ignore-plugin/index.html b/plugins/watch-ignore-plugin/index.html
index 9127d7d796da..fc43604dc3e5 100644
--- a/plugins/watch-ignore-plugin/index.html
+++ b/plugins/watch-ignore-plugin/index.html
@@ -1 +1 @@
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/prod-assets-manifest.json b/prod-assets-manifest.json
index 9e9e331f3978..bc77df67b775 100644
--- a/prod-assets-manifest.json
+++ b/prod-assets-manifest.json
@@ -1 +1 @@
-{"js":["/vendor.a8883abd3205da0f.js","/index.37a1425374f0326d.js"],"css":["/index.fd328ed094fff3af.css","/5701.cbcace1b23f13382.css"]}
\ No newline at end of file
+{"js":["/vendor.a8883abd3205da0f.js","/index.4075e9f7234b5fad.js"],"css":["/index.fd328ed094fff3af.css","/5701.cbcace1b23f13382.css"]}
\ No newline at end of file
diff --git a/sitemap.xml b/sitemap.xml
index 2547a31b169f..f5da38534e8f 100644
--- a/sitemap.xml
+++ b/sitemap.xml
@@ -18,6 +18,9 @@
https://webpack.js.org/comparison
+
+ https://webpack.js.org/concepts
+ https://webpack.js.org/configuration
@@ -45,9 +48,6 @@
https://webpack.js.org/migrate
-
- https://webpack.js.org/concepts
- https://webpack.js.org/migrating
@@ -126,6 +126,51 @@
https://webpack.js.org/blog/printable
+
+ https://webpack.js.org/concepts/configuration
+
+
+ https://webpack.js.org/concepts/dependency-graph
+
+
+ https://webpack.js.org/concepts/entry-points
+
+
+ https://webpack.js.org/concepts/hot-module-replacement
+
+
+ https://webpack.js.org/concepts/loaders
+
+
+ https://webpack.js.org/concepts/manifest
+
+
+ https://webpack.js.org/concepts/mode
+
+
+ https://webpack.js.org/concepts/module-federation
+
+
+ https://webpack.js.org/concepts/module-resolution
+
+
+ https://webpack.js.org/concepts/modules
+
+
+ https://webpack.js.org/concepts/output
+
+
+ https://webpack.js.org/concepts/plugins
+
+
+ https://webpack.js.org/concepts/targets
+
+
+ https://webpack.js.org/concepts/under-the-hood
+
+
+ https://webpack.js.org/concepts/why-webpack
+ https://webpack.js.org/configuration/cache
@@ -198,6 +243,9 @@
https://webpack.js.org/contribute/release-process
+
+ https://webpack.js.org/contribute/writers-guide
+ https://webpack.js.org/contribute/writing-a-loader
@@ -411,51 +459,6 @@
https://webpack.js.org/migrate/5
-
- https://webpack.js.org/concepts/configuration
-
-
- https://webpack.js.org/concepts/dependency-graph
-
-
- https://webpack.js.org/concepts/entry-points
-
-
- https://webpack.js.org/concepts/hot-module-replacement
-
-
- https://webpack.js.org/concepts/loaders
-
-
- https://webpack.js.org/concepts/manifest
-
-
- https://webpack.js.org/concepts/mode
-
-
- https://webpack.js.org/concepts/module-federation
-
-
- https://webpack.js.org/concepts/module-resolution
-
-
- https://webpack.js.org/concepts/modules
-
-
- https://webpack.js.org/concepts/output
-
-
- https://webpack.js.org/concepts/plugins
-
-
- https://webpack.js.org/concepts/targets
-
-
- https://webpack.js.org/concepts/under-the-hood
-
-
- https://webpack.js.org/concepts/why-webpack
- https://webpack.js.org/plugins/NoEmitOnErrorsPlugin
@@ -507,9 +510,6 @@
https://webpack.js.org/plugins/html-minimizer-webpack-plugin
-
- https://webpack.js.org/contribute/writers-guide
- https://webpack.js.org/plugins/html-webpack-plugin
diff --git a/sw.js b/sw.js
index 5273fb49af7e..88b52228277e 100644
--- a/sw.js
+++ b/sw.js
@@ -1 +1 @@
-!function(){"use strict";var e={192:function(){try{self["workbox:cacheable-response:7.0.0"]&&_()}catch(e){}},487:function(){try{self["workbox:core:7.0.0"]&&_()}catch(e){}},403:function(){try{self["workbox:expiration:7.0.0"]&&_()}catch(e){}},815:function(){try{self["workbox:routing:7.0.0"]&&_()}catch(e){}},445:function(){try{self["workbox:strategies:7.0.0"]&&_()}catch(e){}}},t={};function s(n){var r=t[n];if(void 0!==r)return r.exports;var a=t[n]={exports:{}};return e[n](a,a.exports,s),a.exports}!function(){s(487);class e extends Error{constructor(e,t){super(((e,...t)=>{let s=e;return t.length>0&&(s+=` :: ${JSON.stringify(t)}`),s})(e,t)),this.name=e,this.details=t}}const t=new Set,n={googleAnalytics:"googleAnalytics",precache:"precache-v2",prefix:"workbox",runtime:"runtime",suffix:"undefined"!=typeof registration?registration.scope:""},r=e=>[n.prefix,e,n.suffix].filter((e=>e&&e.length>0)).join("-"),a=e=>e||r(n.runtime);function i(e,t){const s=new URL(e);for(const e of t)s.searchParams.delete(e);return s.href}function o(e){e.then((()=>{}))}class c{constructor(){this.promise=new Promise(((e,t)=>{this.resolve=e,this.reject=t}))}}function h(e){return new Promise((t=>setTimeout(t,e)))}const u={get googleAnalytics(){return e||r(n.googleAnalytics);var e},get precache(){return e||r(n.precache);var e},get prefix(){return n.prefix},get runtime(){return a()},get suffix(){return n.suffix}};s(815);const l=e=>e&&"object"==typeof e?e:{handle:e};class d{constructor(e,t,s="GET"){this.handler=l(t),this.match=e,this.method=s}setCatchHandler(e){this.catchHandler=l(e)}}class p extends d{constructor(e,t,s){super((({url:t})=>{const s=e.exec(t.href);if(s&&(t.origin===location.origin||0===s.index))return s.slice(1)}),t,s)}}class f{constructor(){this._routes=new Map,this._defaultHandlerMap=new Map}get routes(){return this._routes}addFetchListener(){self.addEventListener("fetch",(e=>{const{request:t}=e,s=this.handleRequest({request:t,event:e});s&&e.respondWith(s)}))}addCacheListener(){self.addEventListener("message",(e=>{if(e.data&&"CACHE_URLS"===e.data.type){const{payload:t}=e.data,s=Promise.all(t.urlsToCache.map((t=>{"string"==typeof t&&(t=[t]);const s=new Request(...t);return this.handleRequest({request:s,event:e})})));e.waitUntil(s),e.ports&&e.ports[0]&&s.then((()=>e.ports[0].postMessage(!0)))}}))}handleRequest({request:e,event:t}){const s=new URL(e.url,location.href);if(!s.protocol.startsWith("http"))return;const n=s.origin===location.origin,{params:r,route:a}=this.findMatchingRoute({event:t,request:e,sameOrigin:n,url:s});let i=a&&a.handler;const o=e.method;if(!i&&this._defaultHandlerMap.has(o)&&(i=this._defaultHandlerMap.get(o)),!i)return;let c;try{c=i.handle({url:s,request:e,event:t,params:r})}catch(e){c=Promise.reject(e)}const h=a&&a.catchHandler;return c instanceof Promise&&(this._catchHandler||h)&&(c=c.catch((async n=>{if(h)try{return await h.handle({url:s,request:e,event:t,params:r})}catch(e){e instanceof Error&&(n=e)}if(this._catchHandler)return this._catchHandler.handle({url:s,request:e,event:t});throw n}))),c}findMatchingRoute({url:e,sameOrigin:t,request:s,event:n}){const r=this._routes.get(s.method)||[];for(const a of r){let r;const i=a.match({url:e,sameOrigin:t,request:s,event:n});if(i)return r=i,(Array.isArray(r)&&0===r.length||i.constructor===Object&&0===Object.keys(i).length||"boolean"==typeof i)&&(r=void 0),{route:a,params:r}}return{}}setDefaultHandler(e,t="GET"){this._defaultHandlerMap.set(t,l(e))}setCatchHandler(e){this._catchHandler=l(e)}registerRoute(e){this._routes.has(e.method)||this._routes.set(e.method,[]),this._routes.get(e.method).push(e)}unregisterRoute(t){if(!this._routes.has(t.method))throw new e("unregister-route-but-not-found-with-method",{method:t.method});const s=this._routes.get(t.method).indexOf(t);if(!(s>-1))throw new e("unregister-route-route-not-registered");this._routes.get(t.method).splice(s,1)}}let m;const w=()=>(m||(m=new f,m.addFetchListener(),m.addCacheListener()),m);function g(t,s,n){let r;if("string"==typeof t){const e=new URL(t,location.href);r=new d((({url:t})=>t.href===e.href),s,n)}else if(t instanceof RegExp)r=new p(t,s,n);else if("function"==typeof t)r=new d(t,s,n);else{if(!(t instanceof d))throw new e("unsupported-route-type",{moduleName:"workbox-routing",funcName:"registerRoute",paramName:"capture"});r=t}return w().registerRoute(r),r}s(192);class _{constructor(e={}){this._statuses=e.statuses,this._headers=e.headers}isResponseCacheable(e){let t=!0;return this._statuses&&(t=this._statuses.includes(e.status)),this._headers&&t&&(t=Object.keys(this._headers).some((t=>e.headers.get(t)===this._headers[t]))),t}}function y(e){return"string"==typeof e?new Request(e):e}s(445);class v{constructor(e,t){this._cacheKeys={},Object.assign(this,t),this.event=t.event,this._strategy=e,this._handlerDeferred=new c,this._extendLifetimePromises=[],this._plugins=[...e.plugins],this._pluginStateMap=new Map;for(const e of this._plugins)this._pluginStateMap.set(e,{});this.event.waitUntil(this._handlerDeferred.promise)}async fetch(t){const{event:s}=this;let n=y(t);if("navigate"===n.mode&&s instanceof FetchEvent&&s.preloadResponse){const e=await s.preloadResponse;if(e)return e}const r=this.hasCallback("fetchDidFail")?n.clone():null;try{for(const e of this.iterateCallbacks("requestWillFetch"))n=await e({request:n.clone(),event:s})}catch(t){if(t instanceof Error)throw new e("plugin-error-request-will-fetch",{thrownErrorMessage:t.message})}const a=n.clone();try{let e;e=await fetch(n,"navigate"===n.mode?void 0:this._strategy.fetchOptions);for(const t of this.iterateCallbacks("fetchDidSucceed"))e=await t({event:s,request:a,response:e});return e}catch(e){throw r&&await this.runCallbacks("fetchDidFail",{error:e,event:s,originalRequest:r.clone(),request:a.clone()}),e}}async fetchAndCachePut(e){const t=await this.fetch(e),s=t.clone();return this.waitUntil(this.cachePut(e,s)),t}async cacheMatch(e){const t=y(e);let s;const{cacheName:n,matchOptions:r}=this._strategy,a=await this.getCacheKey(t,"read"),i=Object.assign(Object.assign({},r),{cacheName:n});s=await caches.match(a,i);for(const e of this.iterateCallbacks("cachedResponseWillBeUsed"))s=await e({cacheName:n,matchOptions:r,cachedResponse:s,request:a,event:this.event})||void 0;return s}async cachePut(s,n){const r=y(s);await h(0);const a=await this.getCacheKey(r,"write");if(!n)throw new e("cache-put-with-no-response",{url:(o=a.url,new URL(String(o),location.href).href.replace(new RegExp(`^${location.origin}`),""))});var o;const c=await this._ensureResponseSafeToCache(n);if(!c)return!1;const{cacheName:u,matchOptions:l}=this._strategy,d=await self.caches.open(u),p=this.hasCallback("cacheDidUpdate"),f=p?await async function(e,t,s,n){const r=i(t.url,s);if(t.url===r)return e.match(t,n);const a=Object.assign(Object.assign({},n),{ignoreSearch:!0}),o=await e.keys(t,a);for(const t of o)if(r===i(t.url,s))return e.match(t,n)}(d,a.clone(),["__WB_REVISION__"],l):null;try{await d.put(a,p?c.clone():c)}catch(e){if(e instanceof Error)throw"QuotaExceededError"===e.name&&await async function(){for(const e of t)await e()}(),e}for(const e of this.iterateCallbacks("cacheDidUpdate"))await e({cacheName:u,oldResponse:f,newResponse:c.clone(),request:a,event:this.event});return!0}async getCacheKey(e,t){const s=`${e.url} | ${t}`;if(!this._cacheKeys[s]){let n=e;for(const e of this.iterateCallbacks("cacheKeyWillBeUsed"))n=y(await e({mode:t,request:n,event:this.event,params:this.params}));this._cacheKeys[s]=n}return this._cacheKeys[s]}hasCallback(e){for(const t of this._strategy.plugins)if(e in t)return!0;return!1}async runCallbacks(e,t){for(const s of this.iterateCallbacks(e))await s(t)}*iterateCallbacks(e){for(const t of this._strategy.plugins)if("function"==typeof t[e]){const s=this._pluginStateMap.get(t),n=n=>{const r=Object.assign(Object.assign({},n),{state:s});return t[e](r)};yield n}}waitUntil(e){return this._extendLifetimePromises.push(e),e}async doneWaiting(){let e;for(;e=this._extendLifetimePromises.shift();)await e}destroy(){this._handlerDeferred.resolve(null)}async _ensureResponseSafeToCache(e){let t=e,s=!1;for(const e of this.iterateCallbacks("cacheWillUpdate"))if(t=await e({request:this.request,response:t,event:this.event})||void 0,s=!0,!t)break;return s||t&&200!==t.status&&(t=void 0),t}}class b{constructor(e={}){this.cacheName=a(e.cacheName),this.plugins=e.plugins||[],this.fetchOptions=e.fetchOptions,this.matchOptions=e.matchOptions}handle(e){const[t]=this.handleAll(e);return t}handleAll(e){e instanceof FetchEvent&&(e={event:e,request:e.request});const t=e.event,s="string"==typeof e.request?new Request(e.request):e.request,n="params"in e?e.params:void 0,r=new v(this,{event:t,request:s,params:n}),a=this._getResponse(r,s,t);return[a,this._awaitComplete(a,r,s,t)]}async _getResponse(t,s,n){let r;await t.runCallbacks("handlerWillStart",{event:n,request:s});try{if(r=await this._handle(s,t),!r||"error"===r.type)throw new e("no-response",{url:s.url})}catch(e){if(e instanceof Error)for(const a of t.iterateCallbacks("handlerDidError"))if(r=await a({error:e,event:n,request:s}),r)break;if(!r)throw e}for(const e of t.iterateCallbacks("handlerWillRespond"))r=await e({event:n,request:s,response:r});return r}async _awaitComplete(e,t,s,n){let r,a;try{r=await e}catch(a){}try{await t.runCallbacks("handlerDidRespond",{event:n,request:s,response:r}),await t.doneWaiting()}catch(e){e instanceof Error&&(a=e)}if(await t.runCallbacks("handlerDidComplete",{event:n,request:s,response:r,error:a}),t.destroy(),a)throw a}}const x={cacheWillUpdate:async({response:e})=>200===e.status||0===e.status?e:null},E=(e,t)=>t.some((t=>e instanceof t));let D,k;const R=new WeakMap,q=new WeakMap,C=new WeakMap,S=new WeakMap,N=new WeakMap;let T={get(e,t,s){if(e instanceof IDBTransaction){if("done"===t)return q.get(e);if("objectStoreNames"===t)return e.objectStoreNames||C.get(e);if("store"===t)return s.objectStoreNames[1]?void 0:s.objectStore(s.objectStoreNames[0])}return L(e[t])},set(e,t,s){return e[t]=s,!0},has(e,t){return e instanceof IDBTransaction&&("done"===t||"store"===t)||t in e}};function M(e){return"function"==typeof e?(t=e)!==IDBDatabase.prototype.transaction||"objectStoreNames"in IDBTransaction.prototype?(k||(k=[IDBCursor.prototype.advance,IDBCursor.prototype.continue,IDBCursor.prototype.continuePrimaryKey])).includes(t)?function(...e){return t.apply(O(this),e),L(R.get(this))}:function(...e){return L(t.apply(O(this),e))}:function(e,...s){const n=t.call(O(this),e,...s);return C.set(n,e.sort?e.sort():[e]),L(n)}:(e instanceof IDBTransaction&&function(e){if(q.has(e))return;const t=new Promise(((t,s)=>{const n=()=>{e.removeEventListener("complete",r),e.removeEventListener("error",a),e.removeEventListener("abort",a)},r=()=>{t(),n()},a=()=>{s(e.error||new DOMException("AbortError","AbortError")),n()};e.addEventListener("complete",r),e.addEventListener("error",a),e.addEventListener("abort",a)}));q.set(e,t)}(e),E(e,D||(D=[IDBDatabase,IDBObjectStore,IDBIndex,IDBCursor,IDBTransaction]))?new Proxy(e,T):e);var t}function L(e){if(e instanceof IDBRequest)return function(e){const t=new Promise(((t,s)=>{const n=()=>{e.removeEventListener("success",r),e.removeEventListener("error",a)},r=()=>{t(L(e.result)),n()},a=()=>{s(e.error),n()};e.addEventListener("success",r),e.addEventListener("error",a)}));return t.then((t=>{t instanceof IDBCursor&&R.set(t,e)})).catch((()=>{})),N.set(t,e),t}(e);if(S.has(e))return S.get(e);const t=M(e);return t!==e&&(S.set(e,t),N.set(t,e)),t}const O=e=>N.get(e),A=["get","getKey","getAll","getAllKeys","count"],I=["put","add","delete","clear"],U=new Map;function P(e,t){if(!(e instanceof IDBDatabase)||t in e||"string"!=typeof t)return;if(U.get(t))return U.get(t);const s=t.replace(/FromIndex$/,""),n=t!==s,r=I.includes(s);if(!(s in(n?IDBIndex:IDBObjectStore).prototype)||!r&&!A.includes(s))return;const a=async function(e,...t){const a=this.transaction(e,r?"readwrite":"readonly");let i=a.store;return n&&(i=i.index(t.shift())),(await Promise.all([i[s](...t),r&&a.done]))[0]};return U.set(t,a),a}var B;B=T,T={...B,get:(e,t,s)=>P(e,t)||B.get(e,t,s),has:(e,t)=>!!P(e,t)||B.has(e,t)},s(403);const j="cache-entries",W=e=>{const t=new URL(e,location.href);return t.hash="",t.href};class H{constructor(e){this._db=null,this._cacheName=e}_upgradeDb(e){const t=e.createObjectStore(j,{keyPath:"id"});t.createIndex("cacheName","cacheName",{unique:!1}),t.createIndex("timestamp","timestamp",{unique:!1})}_upgradeDbAndDeleteOldDbs(e){this._upgradeDb(e),this._cacheName&&function(e,{blocked:t}={}){const s=indexedDB.deleteDatabase(e);t&&s.addEventListener("blocked",(()=>t())),L(s).then((()=>{}))}(this._cacheName)}async setTimestamp(e,t){const s={url:e=W(e),timestamp:t,cacheName:this._cacheName,id:this._getId(e)},n=(await this.getDb()).transaction(j,"readwrite",{durability:"relaxed"});await n.store.put(s),await n.done}async getTimestamp(e){const t=await this.getDb(),s=await t.get(j,this._getId(e));return null==s?void 0:s.timestamp}async expireEntries(e,t){const s=await this.getDb();let n=await s.transaction(j).store.index("timestamp").openCursor(null,"prev");const r=[];let a=0;for(;n;){const s=n.value;s.cacheName===this._cacheName&&(e&&s.timestamp=t?r.push(n.value):a++),n=await n.continue()}const i=[];for(const e of r)await s.delete(j,e.id),i.push(e.url);return i}_getId(e){return this._cacheName+"|"+W(e)}async getDb(){return this._db||(this._db=await function(e,t,{blocked:s,upgrade:n,blocking:r,terminated:a}={}){const i=indexedDB.open(e,t),o=L(i);return n&&i.addEventListener("upgradeneeded",(e=>{n(L(i.result),e.oldVersion,e.newVersion,L(i.transaction))})),s&&i.addEventListener("blocked",(()=>s())),o.then((e=>{a&&e.addEventListener("close",(()=>a())),r&&e.addEventListener("versionchange",(()=>r()))})).catch((()=>{})),o}("workbox-expiration",1,{upgrade:this._upgradeDbAndDeleteOldDbs.bind(this)})),this._db}}class F{constructor(e,t={}){this._isRunning=!1,this._rerunRequested=!1,this._maxEntries=t.maxEntries,this._maxAgeSeconds=t.maxAgeSeconds,this._matchOptions=t.matchOptions,this._cacheName=e,this._timestampModel=new H(e)}async expireEntries(){if(this._isRunning)return void(this._rerunRequested=!0);this._isRunning=!0;const e=this._maxAgeSeconds?Date.now()-1e3*this._maxAgeSeconds:0,t=await this._timestampModel.expireEntries(e,this._maxEntries),s=await self.caches.open(this._cacheName);for(const e of t)await s.delete(e,this._matchOptions);this._isRunning=!1,this._rerunRequested&&(this._rerunRequested=!1,o(this.expireEntries()))}async updateTimestamp(e){await this._timestampModel.setTimestamp(e,Date.now())}async isURLExpired(e){if(this._maxAgeSeconds){const t=await this._timestampModel.getTimestamp(e),s=Date.now()-1e3*this._maxAgeSeconds;return void 0===t||tnew URL(e.url,self.location).href));var V;self.addEventListener("install",(e=>{e.waitUntil(caches.open(K).then((e=>e.addAll($))))})),self.addEventListener("activate",(e=>{e.waitUntil(caches.open(K).then((e=>{e.keys().then((t=>{t.forEach((t=>{$.includes(t.url)||e.delete(t)}))}))})))})),g((e=>{let{url:t}=e;return $.includes(t.href)}),new class extends b{constructor(e={}){super(e),this.plugins.some((e=>"cacheWillUpdate"in e))||this.plugins.unshift(x),this._networkTimeoutSeconds=e.networkTimeoutSeconds||0}async _handle(t,s){const n=[],r=[];let a;if(this._networkTimeoutSeconds){const{id:e,promise:i}=this._getTimeoutPromise({request:t,logs:n,handler:s});a=e,r.push(i)}const i=this._getNetworkPromise({timeoutId:a,request:t,logs:n,handler:s});r.push(i);const o=await s.waitUntil((async()=>await s.waitUntil(Promise.race(r))||await i)());if(!o)throw new e("no-response",{url:t.url});return o}_getTimeoutPromise({request:e,logs:t,handler:s}){let n;return{promise:new Promise((t=>{n=setTimeout((async()=>{t(await s.cacheMatch(e))}),1e3*this._networkTimeoutSeconds)})),id:n}}async _getNetworkPromise({timeoutId:e,request:t,logs:s,handler:n}){let r,a;try{a=await n.fetchAndCachePut(t)}catch(e){e instanceof Error&&(r=e)}return e&&clearTimeout(e),!r&&a||(a=await n.cacheMatch(t)),a}}({cacheName:K})),g(/https:\/\/fonts\.gstatic\.com/,new class extends b{constructor(e={}){super(e),this.plugins.some((e=>"cacheWillUpdate"in e))||this.plugins.unshift(x)}async _handle(t,s){const n=s.fetchAndCachePut(t).catch((()=>{}));s.waitUntil(n);let r,a=await s.cacheMatch(t);if(a);else try{a=await n}catch(e){e instanceof Error&&(r=e)}if(!a)throw new e("no-response",{url:t.url,error:r});return a}}({cacheName:"google-fonts-cache",plugins:[new class{constructor(e){this.cacheWillUpdate=async({response:e})=>this._cacheableResponse.isResponseCacheable(e)?e:null,this._cacheableResponse=new _(e)}}({statuses:[200]}),new class{constructor(e={}){var s;this.cachedResponseWillBeUsed=async({event:e,request:t,cacheName:s,cachedResponse:n})=>{if(!n)return null;const r=this._isResponseDateFresh(n),a=this._getCacheExpiration(s);o(a.expireEntries());const i=a.updateTimestamp(t.url);if(e)try{e.waitUntil(i)}catch(e){}return r?n:null},this.cacheDidUpdate=async({cacheName:e,request:t})=>{const s=this._getCacheExpiration(e);await s.updateTimestamp(t.url),await s.expireEntries()},this._config=e,this._maxAgeSeconds=e.maxAgeSeconds,this._cacheExpirations=new Map,e.purgeOnQuotaError&&(s=()=>this.deleteCacheAndMetadata(),t.add(s))}_getCacheExpiration(t){if(t===a())throw new e("expire-custom-caches-only");let s=this._cacheExpirations.get(t);return s||(s=new F(t,this._config),this._cacheExpirations.set(t,s)),s}_isResponseDateFresh(e){if(!this._maxAgeSeconds)return!0;const t=this._getDateHeaderTimestamp(e);return null===t||t>=Date.now()-1e3*this._maxAgeSeconds}_getDateHeaderTimestamp(e){if(!e.headers.has("date"))return null;const t=e.headers.get("date"),s=new Date(t).getTime();return isNaN(s)?null:s}async deleteCacheAndMetadata(){for(const[e,t]of this._cacheExpirations)await self.caches.delete(e),await t.delete();this._cacheExpirations=new Map}}({maxAgeSeconds:31536e3,maxEntries:30})]})),V=new class extends b{constructor(e={}){super(e),this._networkTimeoutSeconds=e.networkTimeoutSeconds||0}async _handle(t,s){let n,r;try{const e=[s.fetch(t)];if(this._networkTimeoutSeconds){const t=h(1e3*this._networkTimeoutSeconds);e.push(t)}if(r=await Promise.race(e),!r)throw new Error(`Timed out the network response after ${this._networkTimeoutSeconds} seconds.`)}catch(e){e instanceof Error&&(n=e)}if(!r)throw new e("no-response",{url:t.url,error:n});return r}},w().setDefaultHandler(V),w().setCatchHandler((e=>{let{event:t}=e;return"document"===t.request.destination?caches.match("/app-shell/index.html"):Response.error()}))}()}();
\ No newline at end of file
+!function(){"use strict";var e={192:function(){try{self["workbox:cacheable-response:7.0.0"]&&_()}catch(e){}},487:function(){try{self["workbox:core:7.0.0"]&&_()}catch(e){}},403:function(){try{self["workbox:expiration:7.0.0"]&&_()}catch(e){}},815:function(){try{self["workbox:routing:7.0.0"]&&_()}catch(e){}},445:function(){try{self["workbox:strategies:7.0.0"]&&_()}catch(e){}}},t={};function s(n){var r=t[n];if(void 0!==r)return r.exports;var a=t[n]={exports:{}};return e[n](a,a.exports,s),a.exports}!function(){s(487);class e extends Error{constructor(e,t){super(((e,...t)=>{let s=e;return t.length>0&&(s+=` :: ${JSON.stringify(t)}`),s})(e,t)),this.name=e,this.details=t}}const t=new Set,n={googleAnalytics:"googleAnalytics",precache:"precache-v2",prefix:"workbox",runtime:"runtime",suffix:"undefined"!=typeof registration?registration.scope:""},r=e=>[n.prefix,e,n.suffix].filter((e=>e&&e.length>0)).join("-"),a=e=>e||r(n.runtime);function i(e,t){const s=new URL(e);for(const e of t)s.searchParams.delete(e);return s.href}function o(e){e.then((()=>{}))}class c{constructor(){this.promise=new Promise(((e,t)=>{this.resolve=e,this.reject=t}))}}function h(e){return new Promise((t=>setTimeout(t,e)))}const u={get googleAnalytics(){return e||r(n.googleAnalytics);var e},get precache(){return e||r(n.precache);var e},get prefix(){return n.prefix},get runtime(){return a()},get suffix(){return n.suffix}};s(815);const l=e=>e&&"object"==typeof e?e:{handle:e};class d{constructor(e,t,s="GET"){this.handler=l(t),this.match=e,this.method=s}setCatchHandler(e){this.catchHandler=l(e)}}class p extends d{constructor(e,t,s){super((({url:t})=>{const s=e.exec(t.href);if(s&&(t.origin===location.origin||0===s.index))return s.slice(1)}),t,s)}}class f{constructor(){this._routes=new Map,this._defaultHandlerMap=new Map}get routes(){return this._routes}addFetchListener(){self.addEventListener("fetch",(e=>{const{request:t}=e,s=this.handleRequest({request:t,event:e});s&&e.respondWith(s)}))}addCacheListener(){self.addEventListener("message",(e=>{if(e.data&&"CACHE_URLS"===e.data.type){const{payload:t}=e.data,s=Promise.all(t.urlsToCache.map((t=>{"string"==typeof t&&(t=[t]);const s=new Request(...t);return this.handleRequest({request:s,event:e})})));e.waitUntil(s),e.ports&&e.ports[0]&&s.then((()=>e.ports[0].postMessage(!0)))}}))}handleRequest({request:e,event:t}){const s=new URL(e.url,location.href);if(!s.protocol.startsWith("http"))return;const n=s.origin===location.origin,{params:r,route:a}=this.findMatchingRoute({event:t,request:e,sameOrigin:n,url:s});let i=a&&a.handler;const o=e.method;if(!i&&this._defaultHandlerMap.has(o)&&(i=this._defaultHandlerMap.get(o)),!i)return;let c;try{c=i.handle({url:s,request:e,event:t,params:r})}catch(e){c=Promise.reject(e)}const h=a&&a.catchHandler;return c instanceof Promise&&(this._catchHandler||h)&&(c=c.catch((async n=>{if(h)try{return await h.handle({url:s,request:e,event:t,params:r})}catch(e){e instanceof Error&&(n=e)}if(this._catchHandler)return this._catchHandler.handle({url:s,request:e,event:t});throw n}))),c}findMatchingRoute({url:e,sameOrigin:t,request:s,event:n}){const r=this._routes.get(s.method)||[];for(const a of r){let r;const i=a.match({url:e,sameOrigin:t,request:s,event:n});if(i)return r=i,(Array.isArray(r)&&0===r.length||i.constructor===Object&&0===Object.keys(i).length||"boolean"==typeof i)&&(r=void 0),{route:a,params:r}}return{}}setDefaultHandler(e,t="GET"){this._defaultHandlerMap.set(t,l(e))}setCatchHandler(e){this._catchHandler=l(e)}registerRoute(e){this._routes.has(e.method)||this._routes.set(e.method,[]),this._routes.get(e.method).push(e)}unregisterRoute(t){if(!this._routes.has(t.method))throw new e("unregister-route-but-not-found-with-method",{method:t.method});const s=this._routes.get(t.method).indexOf(t);if(!(s>-1))throw new e("unregister-route-route-not-registered");this._routes.get(t.method).splice(s,1)}}let m;const w=()=>(m||(m=new f,m.addFetchListener(),m.addCacheListener()),m);function g(t,s,n){let r;if("string"==typeof t){const e=new URL(t,location.href);r=new d((({url:t})=>t.href===e.href),s,n)}else if(t instanceof RegExp)r=new p(t,s,n);else if("function"==typeof t)r=new d(t,s,n);else{if(!(t instanceof d))throw new e("unsupported-route-type",{moduleName:"workbox-routing",funcName:"registerRoute",paramName:"capture"});r=t}return w().registerRoute(r),r}s(192);class _{constructor(e={}){this._statuses=e.statuses,this._headers=e.headers}isResponseCacheable(e){let t=!0;return this._statuses&&(t=this._statuses.includes(e.status)),this._headers&&t&&(t=Object.keys(this._headers).some((t=>e.headers.get(t)===this._headers[t]))),t}}function y(e){return"string"==typeof e?new Request(e):e}s(445);class v{constructor(e,t){this._cacheKeys={},Object.assign(this,t),this.event=t.event,this._strategy=e,this._handlerDeferred=new c,this._extendLifetimePromises=[],this._plugins=[...e.plugins],this._pluginStateMap=new Map;for(const e of this._plugins)this._pluginStateMap.set(e,{});this.event.waitUntil(this._handlerDeferred.promise)}async fetch(t){const{event:s}=this;let n=y(t);if("navigate"===n.mode&&s instanceof FetchEvent&&s.preloadResponse){const e=await s.preloadResponse;if(e)return e}const r=this.hasCallback("fetchDidFail")?n.clone():null;try{for(const e of this.iterateCallbacks("requestWillFetch"))n=await e({request:n.clone(),event:s})}catch(t){if(t instanceof Error)throw new e("plugin-error-request-will-fetch",{thrownErrorMessage:t.message})}const a=n.clone();try{let e;e=await fetch(n,"navigate"===n.mode?void 0:this._strategy.fetchOptions);for(const t of this.iterateCallbacks("fetchDidSucceed"))e=await t({event:s,request:a,response:e});return e}catch(e){throw r&&await this.runCallbacks("fetchDidFail",{error:e,event:s,originalRequest:r.clone(),request:a.clone()}),e}}async fetchAndCachePut(e){const t=await this.fetch(e),s=t.clone();return this.waitUntil(this.cachePut(e,s)),t}async cacheMatch(e){const t=y(e);let s;const{cacheName:n,matchOptions:r}=this._strategy,a=await this.getCacheKey(t,"read"),i=Object.assign(Object.assign({},r),{cacheName:n});s=await caches.match(a,i);for(const e of this.iterateCallbacks("cachedResponseWillBeUsed"))s=await e({cacheName:n,matchOptions:r,cachedResponse:s,request:a,event:this.event})||void 0;return s}async cachePut(s,n){const r=y(s);await h(0);const a=await this.getCacheKey(r,"write");if(!n)throw new e("cache-put-with-no-response",{url:(o=a.url,new URL(String(o),location.href).href.replace(new RegExp(`^${location.origin}`),""))});var o;const c=await this._ensureResponseSafeToCache(n);if(!c)return!1;const{cacheName:u,matchOptions:l}=this._strategy,d=await self.caches.open(u),p=this.hasCallback("cacheDidUpdate"),f=p?await async function(e,t,s,n){const r=i(t.url,s);if(t.url===r)return e.match(t,n);const a=Object.assign(Object.assign({},n),{ignoreSearch:!0}),o=await e.keys(t,a);for(const t of o)if(r===i(t.url,s))return e.match(t,n)}(d,a.clone(),["__WB_REVISION__"],l):null;try{await d.put(a,p?c.clone():c)}catch(e){if(e instanceof Error)throw"QuotaExceededError"===e.name&&await async function(){for(const e of t)await e()}(),e}for(const e of this.iterateCallbacks("cacheDidUpdate"))await e({cacheName:u,oldResponse:f,newResponse:c.clone(),request:a,event:this.event});return!0}async getCacheKey(e,t){const s=`${e.url} | ${t}`;if(!this._cacheKeys[s]){let n=e;for(const e of this.iterateCallbacks("cacheKeyWillBeUsed"))n=y(await e({mode:t,request:n,event:this.event,params:this.params}));this._cacheKeys[s]=n}return this._cacheKeys[s]}hasCallback(e){for(const t of this._strategy.plugins)if(e in t)return!0;return!1}async runCallbacks(e,t){for(const s of this.iterateCallbacks(e))await s(t)}*iterateCallbacks(e){for(const t of this._strategy.plugins)if("function"==typeof t[e]){const s=this._pluginStateMap.get(t),n=n=>{const r=Object.assign(Object.assign({},n),{state:s});return t[e](r)};yield n}}waitUntil(e){return this._extendLifetimePromises.push(e),e}async doneWaiting(){let e;for(;e=this._extendLifetimePromises.shift();)await e}destroy(){this._handlerDeferred.resolve(null)}async _ensureResponseSafeToCache(e){let t=e,s=!1;for(const e of this.iterateCallbacks("cacheWillUpdate"))if(t=await e({request:this.request,response:t,event:this.event})||void 0,s=!0,!t)break;return s||t&&200!==t.status&&(t=void 0),t}}class b{constructor(e={}){this.cacheName=a(e.cacheName),this.plugins=e.plugins||[],this.fetchOptions=e.fetchOptions,this.matchOptions=e.matchOptions}handle(e){const[t]=this.handleAll(e);return t}handleAll(e){e instanceof FetchEvent&&(e={event:e,request:e.request});const t=e.event,s="string"==typeof e.request?new Request(e.request):e.request,n="params"in e?e.params:void 0,r=new v(this,{event:t,request:s,params:n}),a=this._getResponse(r,s,t);return[a,this._awaitComplete(a,r,s,t)]}async _getResponse(t,s,n){let r;await t.runCallbacks("handlerWillStart",{event:n,request:s});try{if(r=await this._handle(s,t),!r||"error"===r.type)throw new e("no-response",{url:s.url})}catch(e){if(e instanceof Error)for(const a of t.iterateCallbacks("handlerDidError"))if(r=await a({error:e,event:n,request:s}),r)break;if(!r)throw e}for(const e of t.iterateCallbacks("handlerWillRespond"))r=await e({event:n,request:s,response:r});return r}async _awaitComplete(e,t,s,n){let r,a;try{r=await e}catch(a){}try{await t.runCallbacks("handlerDidRespond",{event:n,request:s,response:r}),await t.doneWaiting()}catch(e){e instanceof Error&&(a=e)}if(await t.runCallbacks("handlerDidComplete",{event:n,request:s,response:r,error:a}),t.destroy(),a)throw a}}const x={cacheWillUpdate:async({response:e})=>200===e.status||0===e.status?e:null},E=(e,t)=>t.some((t=>e instanceof t));let D,k;const R=new WeakMap,q=new WeakMap,C=new WeakMap,S=new WeakMap,N=new WeakMap;let T={get(e,t,s){if(e instanceof IDBTransaction){if("done"===t)return q.get(e);if("objectStoreNames"===t)return e.objectStoreNames||C.get(e);if("store"===t)return s.objectStoreNames[1]?void 0:s.objectStore(s.objectStoreNames[0])}return L(e[t])},set(e,t,s){return e[t]=s,!0},has(e,t){return e instanceof IDBTransaction&&("done"===t||"store"===t)||t in e}};function M(e){return"function"==typeof e?(t=e)!==IDBDatabase.prototype.transaction||"objectStoreNames"in IDBTransaction.prototype?(k||(k=[IDBCursor.prototype.advance,IDBCursor.prototype.continue,IDBCursor.prototype.continuePrimaryKey])).includes(t)?function(...e){return t.apply(O(this),e),L(R.get(this))}:function(...e){return L(t.apply(O(this),e))}:function(e,...s){const n=t.call(O(this),e,...s);return C.set(n,e.sort?e.sort():[e]),L(n)}:(e instanceof IDBTransaction&&function(e){if(q.has(e))return;const t=new Promise(((t,s)=>{const n=()=>{e.removeEventListener("complete",r),e.removeEventListener("error",a),e.removeEventListener("abort",a)},r=()=>{t(),n()},a=()=>{s(e.error||new DOMException("AbortError","AbortError")),n()};e.addEventListener("complete",r),e.addEventListener("error",a),e.addEventListener("abort",a)}));q.set(e,t)}(e),E(e,D||(D=[IDBDatabase,IDBObjectStore,IDBIndex,IDBCursor,IDBTransaction]))?new Proxy(e,T):e);var t}function L(e){if(e instanceof IDBRequest)return function(e){const t=new Promise(((t,s)=>{const n=()=>{e.removeEventListener("success",r),e.removeEventListener("error",a)},r=()=>{t(L(e.result)),n()},a=()=>{s(e.error),n()};e.addEventListener("success",r),e.addEventListener("error",a)}));return t.then((t=>{t instanceof IDBCursor&&R.set(t,e)})).catch((()=>{})),N.set(t,e),t}(e);if(S.has(e))return S.get(e);const t=M(e);return t!==e&&(S.set(e,t),N.set(t,e)),t}const O=e=>N.get(e),A=["get","getKey","getAll","getAllKeys","count"],I=["put","add","delete","clear"],U=new Map;function P(e,t){if(!(e instanceof IDBDatabase)||t in e||"string"!=typeof t)return;if(U.get(t))return U.get(t);const s=t.replace(/FromIndex$/,""),n=t!==s,r=I.includes(s);if(!(s in(n?IDBIndex:IDBObjectStore).prototype)||!r&&!A.includes(s))return;const a=async function(e,...t){const a=this.transaction(e,r?"readwrite":"readonly");let i=a.store;return n&&(i=i.index(t.shift())),(await Promise.all([i[s](...t),r&&a.done]))[0]};return U.set(t,a),a}var B;B=T,T={...B,get:(e,t,s)=>P(e,t)||B.get(e,t,s),has:(e,t)=>!!P(e,t)||B.has(e,t)},s(403);const j="cache-entries",W=e=>{const t=new URL(e,location.href);return t.hash="",t.href};class H{constructor(e){this._db=null,this._cacheName=e}_upgradeDb(e){const t=e.createObjectStore(j,{keyPath:"id"});t.createIndex("cacheName","cacheName",{unique:!1}),t.createIndex("timestamp","timestamp",{unique:!1})}_upgradeDbAndDeleteOldDbs(e){this._upgradeDb(e),this._cacheName&&function(e,{blocked:t}={}){const s=indexedDB.deleteDatabase(e);t&&s.addEventListener("blocked",(()=>t())),L(s).then((()=>{}))}(this._cacheName)}async setTimestamp(e,t){const s={url:e=W(e),timestamp:t,cacheName:this._cacheName,id:this._getId(e)},n=(await this.getDb()).transaction(j,"readwrite",{durability:"relaxed"});await n.store.put(s),await n.done}async getTimestamp(e){const t=await this.getDb(),s=await t.get(j,this._getId(e));return null==s?void 0:s.timestamp}async expireEntries(e,t){const s=await this.getDb();let n=await s.transaction(j).store.index("timestamp").openCursor(null,"prev");const r=[];let a=0;for(;n;){const s=n.value;s.cacheName===this._cacheName&&(e&&s.timestamp=t?r.push(n.value):a++),n=await n.continue()}const i=[];for(const e of r)await s.delete(j,e.id),i.push(e.url);return i}_getId(e){return this._cacheName+"|"+W(e)}async getDb(){return this._db||(this._db=await function(e,t,{blocked:s,upgrade:n,blocking:r,terminated:a}={}){const i=indexedDB.open(e,t),o=L(i);return n&&i.addEventListener("upgradeneeded",(e=>{n(L(i.result),e.oldVersion,e.newVersion,L(i.transaction))})),s&&i.addEventListener("blocked",(()=>s())),o.then((e=>{a&&e.addEventListener("close",(()=>a())),r&&e.addEventListener("versionchange",(()=>r()))})).catch((()=>{})),o}("workbox-expiration",1,{upgrade:this._upgradeDbAndDeleteOldDbs.bind(this)})),this._db}}class F{constructor(e,t={}){this._isRunning=!1,this._rerunRequested=!1,this._maxEntries=t.maxEntries,this._maxAgeSeconds=t.maxAgeSeconds,this._matchOptions=t.matchOptions,this._cacheName=e,this._timestampModel=new H(e)}async expireEntries(){if(this._isRunning)return void(this._rerunRequested=!0);this._isRunning=!0;const e=this._maxAgeSeconds?Date.now()-1e3*this._maxAgeSeconds:0,t=await this._timestampModel.expireEntries(e,this._maxEntries),s=await self.caches.open(this._cacheName);for(const e of t)await s.delete(e,this._matchOptions);this._isRunning=!1,this._rerunRequested&&(this._rerunRequested=!1,o(this.expireEntries()))}async updateTimestamp(e){await this._timestampModel.setTimestamp(e,Date.now())}async isURLExpired(e){if(this._maxAgeSeconds){const t=await this._timestampModel.getTimestamp(e),s=Date.now()-1e3*this._maxAgeSeconds;return void 0===t||tnew URL(e.url,self.location).href));var V;self.addEventListener("install",(e=>{e.waitUntil(caches.open(K).then((e=>e.addAll($))))})),self.addEventListener("activate",(e=>{e.waitUntil(caches.open(K).then((e=>{e.keys().then((t=>{t.forEach((t=>{$.includes(t.url)||e.delete(t)}))}))})))})),g((e=>{let{url:t}=e;return $.includes(t.href)}),new class extends b{constructor(e={}){super(e),this.plugins.some((e=>"cacheWillUpdate"in e))||this.plugins.unshift(x),this._networkTimeoutSeconds=e.networkTimeoutSeconds||0}async _handle(t,s){const n=[],r=[];let a;if(this._networkTimeoutSeconds){const{id:e,promise:i}=this._getTimeoutPromise({request:t,logs:n,handler:s});a=e,r.push(i)}const i=this._getNetworkPromise({timeoutId:a,request:t,logs:n,handler:s});r.push(i);const o=await s.waitUntil((async()=>await s.waitUntil(Promise.race(r))||await i)());if(!o)throw new e("no-response",{url:t.url});return o}_getTimeoutPromise({request:e,logs:t,handler:s}){let n;return{promise:new Promise((t=>{n=setTimeout((async()=>{t(await s.cacheMatch(e))}),1e3*this._networkTimeoutSeconds)})),id:n}}async _getNetworkPromise({timeoutId:e,request:t,logs:s,handler:n}){let r,a;try{a=await n.fetchAndCachePut(t)}catch(e){e instanceof Error&&(r=e)}return e&&clearTimeout(e),!r&&a||(a=await n.cacheMatch(t)),a}}({cacheName:K})),g(/https:\/\/fonts\.gstatic\.com/,new class extends b{constructor(e={}){super(e),this.plugins.some((e=>"cacheWillUpdate"in e))||this.plugins.unshift(x)}async _handle(t,s){const n=s.fetchAndCachePut(t).catch((()=>{}));s.waitUntil(n);let r,a=await s.cacheMatch(t);if(a);else try{a=await n}catch(e){e instanceof Error&&(r=e)}if(!a)throw new e("no-response",{url:t.url,error:r});return a}}({cacheName:"google-fonts-cache",plugins:[new class{constructor(e){this.cacheWillUpdate=async({response:e})=>this._cacheableResponse.isResponseCacheable(e)?e:null,this._cacheableResponse=new _(e)}}({statuses:[200]}),new class{constructor(e={}){var s;this.cachedResponseWillBeUsed=async({event:e,request:t,cacheName:s,cachedResponse:n})=>{if(!n)return null;const r=this._isResponseDateFresh(n),a=this._getCacheExpiration(s);o(a.expireEntries());const i=a.updateTimestamp(t.url);if(e)try{e.waitUntil(i)}catch(e){}return r?n:null},this.cacheDidUpdate=async({cacheName:e,request:t})=>{const s=this._getCacheExpiration(e);await s.updateTimestamp(t.url),await s.expireEntries()},this._config=e,this._maxAgeSeconds=e.maxAgeSeconds,this._cacheExpirations=new Map,e.purgeOnQuotaError&&(s=()=>this.deleteCacheAndMetadata(),t.add(s))}_getCacheExpiration(t){if(t===a())throw new e("expire-custom-caches-only");let s=this._cacheExpirations.get(t);return s||(s=new F(t,this._config),this._cacheExpirations.set(t,s)),s}_isResponseDateFresh(e){if(!this._maxAgeSeconds)return!0;const t=this._getDateHeaderTimestamp(e);return null===t||t>=Date.now()-1e3*this._maxAgeSeconds}_getDateHeaderTimestamp(e){if(!e.headers.has("date"))return null;const t=e.headers.get("date"),s=new Date(t).getTime();return isNaN(s)?null:s}async deleteCacheAndMetadata(){for(const[e,t]of this._cacheExpirations)await self.caches.delete(e),await t.delete();this._cacheExpirations=new Map}}({maxAgeSeconds:31536e3,maxEntries:30})]})),V=new class extends b{constructor(e={}){super(e),this._networkTimeoutSeconds=e.networkTimeoutSeconds||0}async _handle(t,s){let n,r;try{const e=[s.fetch(t)];if(this._networkTimeoutSeconds){const t=h(1e3*this._networkTimeoutSeconds);e.push(t)}if(r=await Promise.race(e),!r)throw new Error(`Timed out the network response after ${this._networkTimeoutSeconds} seconds.`)}catch(e){e instanceof Error&&(n=e)}if(!r)throw new e("no-response",{url:t.url,error:n});return r}},w().setDefaultHandler(V),w().setCatchHandler((e=>{let{event:t}=e;return"document"===t.request.destination?caches.match("/app-shell/index.html"):Response.error()}))}()}();
\ No newline at end of file