All Versions
76
Latest Version
Avg Release Cycle
3 days
Latest Release
314 days ago

Changelog History
Page 4

  • v5.0.0-beta.29 Changes

    August 28, 2020

    ๐Ÿ’ฅ Breaking Changes

    • ๐Ÿšš config options have moved
      • cache.managedPaths/immutablePaths -> snapshot.managedPaths/immutablePaths
      • output.hotUpdateFunction -> output.hotUpdateGlobal
      • output.jsonpFunction -> output.chunkLoadingGlobal
      • output.chunkCallbackFunction -> output.chunkLoadingGlobal

    ๐Ÿ”‹ Features

    • new RegExp() can be evaluated now, e. g. when used in require.context
    • โž• add additional logging for FileSystemInfo regarding snapshotting
    • ๐Ÿ†• new config options how snapshots are created.
      • snapshot.module: Snapshots for building of modules
      • snapshot.resolve: Snapshots for resolving of requests
      • snapshot.buildDependencies: Snapshots for build dependencies when using the persistent cache
      • snapshot.resolveBuildDependencies: Snapshots for resolving of build dependencies when using the persistent cache
    • ๐Ÿ†• new options:
      • output.chunkLoading: The method of loading chunks (methods included by default are 'jsonp' (web), 'import-scripts' (WebWorker), 'require' (sync node.js), 'async-node' (async node.js), but others might be added by plugins).
      • output.chunkFormat: The format of chunks (formats included by default are 'array-push' (web/WebWorker), 'commonjs' (node.js), but others might be added by plugins).
      • defaults are chosen based on target option
      • output.enabledChunkLoadingTypes: List of chunk loading types enabled. Will be automatically filled by webpack. Only needed when using a function as entry option and returning chunkLoading option from there.
      • entry.*.chunkLoading: Like output.chunkLoading but only for this entry.
    • ๐Ÿ”Œ output.library and output.chunkLoading now also allow any string in schema, to support adding custom types via plugins.

    ๐Ÿ”„ Changes

    • in production mode module snapshotting will use timestamp + hash mode to allow persistent caching on CI
    • 0๏ธโƒฃ output.globalObject defaults to self instead of window of web-like targets

    ๐Ÿ›  Bugfixes

    • ๐Ÿ›  fix generated code for export default function*() {}
    • ๐Ÿ‘ allow caching of modules that are not parsed because of module.noParse
    • ๐Ÿ›  fix generated code of new.target
    • avoid using require("module").builtinModules for getting node.js built-in modules
    • ๐Ÿ›  fix watching when more than 2000 directories are watched on MacOS

    ๐ŸŽ Performance

    • ๐ŸŽ Performance improvements for snapshotting
      • snapshot content other than file timestamps is deduplicated
    • lazy deserialize inner source in CachedSource
    • ๐Ÿ”€ avoid touching LazySet for cache dependencies from ModuleFactory to avoid eager merging
    • ๐ŸŽ refactor how cache dependencies are read from Modules for performance
    • store cache dependencies instead of Snapshot to avoid duplicate serialization and allow deduplication
    • create multiple files when more then 50k cache items are stored at once
    • โšก๏ธ optimize serialization of lazy deserialized content in BinaryMiddleware
  • v5.0.0-beta.28 Changes

    August 20, 2020

    ๐Ÿ”‹ Features

    • terser 5
    • ๐Ÿ”ฆ expose missing plugins for applying targets

    ๐Ÿ›  Bugfixes

    • ๐Ÿ›  fix crash in RealContentHashPlugin when using Source-like object instead of real Source objects (or old webpack-sources versions)

    ๐ŸŽ Performance

    • ๐Ÿ”Œ cache Source access in RealContentHashPlugin
  • v5.0.0-beta.27 Changes

    August 19, 2020

    ๐Ÿ”‹ Features

    • ๐Ÿ‘ static analysis for CommonJS now supports reexports via
      • module.exports = require("...")
      • module.exports.a.b.c = require("...").a.b.c
      • Unused exports for these constructs are elimiated, but export names are not mangled yet
    • โž• add optimization.realContentHash option
      • defaults to true in production mode
      • a real content hash is calculated for [contenthash] after asset processing, e. g. for minimizing etc.
    • โž• add output.charset option
      • defaults to true
      • setting it to false omits the charset attribute on injected scripts
    • ๐Ÿ”ฆ expose require("webpack-sources") as require("webpack").sources
      • avoids version conflict with different webpack-sources version
      • webpack should be consumes as peerDependecy by plugins

    ๐Ÿ›  Bugfixes

    • ๐Ÿ›  fixes a crash with TypeError: Cannot mix BigInt and other types, use explicit conversions in the SplitChunksPlugin in rare edge cases
    • Persistent Cache can serialize unaffected cache items even when other cache items fail to serialize
      • Shows all serializing problems as warnings
  • v5.0.0-beta.26 Changes

    August 14, 2020

    ๐Ÿ”‹ Features

    • โž• add error message when there are conflicting star exports
    • track reexports in opimization.providedExports
    • display reexports in output.pathinfo
    • ๐Ÿ‘Œ improve performance
      • chunk graph building
      • optimization.splitChunks
      • hashing
    • โž• add more statistics for performance-related issues

    ๐Ÿ›  Bugfixes

    • ๐Ÿ›  fix problem with script externals where the url contains @
    • ๐Ÿ‘Œ improves handling of dynamic modules for reexporting
    • ๐Ÿ— build errors are no longer treated as warnings for optional modules
  • v5.0.0-beta.25 Changes

    August 10, 2020

    ๐Ÿ”‹ Features

    • ๐Ÿฑ Compilation.deleteAsset to correctly delete an assets and non-shared related assets
    • โž• Add support for optional chaining a?.b in parsing and evaluation
      • allows e. g. import.meta.webpackHot?.accept("./dep")

    ๐Ÿ›  Bugfixes

    • โš™ runtime chunk is now part of the generated entry info in the chunk
    • โฌ†๏ธ upgrade watchpack to beta 14
      • merged watchers to recursive watchers when reaching watcher limit (MacOS: 2,000, Windows: 10,000)
      • This fixes watching errors when watching more than 4096 directories on MacOS
    • import() of async externals now works correctly
    • ๐Ÿ›  fix variable declarations in switch cases
  • v5.0.0-beta.24 Changes

    August 05, 2020

    ๐Ÿ”‹ Features

    • ๐Ÿ†• new stats.relatedAssets option to show assets that are related to other assets (like SourceMap, compressed version, etc.)
    • โœ‚ removed assets table in favor of assets list in stats text
    • ๐Ÿ”€ assetInfo from emitAsset will now merge when nested objects or arrays are used
    • โœ‚ remove experiments.importAsync and enable it by default
    • โœ‚ remove experiments.importAwait
    • ๐Ÿฑ [query] is now a valid placeholder when for paths based on a filename like assets
    • output.assetModuleFilename includes [query] now
      • This allows to use querystrings with asset modules, e. g. when using some kind of server-side processing layer for assets

    ๐Ÿ›  Bugfixes

    • ๐Ÿ›  fix a problem were context modules misses some items when remove.modules is used
    • ๐Ÿ›  fixes a problem when multiple webpack runtimes try to load the same script (e. g. as script external with Module Federation)
    • ๐Ÿ›  fix a problem where shareScope is ignored in ModuleFederationPlugin and SharePlugin
    • ๐Ÿ—„ exclude deprecated --module-rules-options from Cli arguments
    • ๐Ÿ›  fixes problems with relative paths when using nested or weird entry names (for web, node, webworker)
    • ๐Ÿ›  fix version comparsion for Module Federation
  • v5.0.0-beta.23 Changes

    August 02, 2020

    Highlights

    โšก๏ธ webpack now optimizes exports and concatenates modules per runtime (often equal entrypoint), which will lead to better optimization when using multiple entrypoints.
    Entrypoints do no longer affect each other when using a runtime per entrypoint.

    โšก๏ธ webpack defaults has been improved to be optimized for http/2 serving (creating more chunks as request limit as been increased).

    ๐Ÿ”‹ Features

    • ๐Ÿ†• new option splitChunks.enforceSizeThreshold resp. splitChunks.cacheGroups[x].enforceSizeThreshold
      • when over this limit, minRemainingSize, maxInitialRequests and maxAsyncRequests are ignore
      • This enforces big chunks to be splitted, e. g. big vendors, even if this adds more requests or keeps small remaining chunks
    • โž• added compilation/compiler.getCache API for easier to use caching
      • also exposes getLazyHashedEtag to plugins
    • ๐Ÿ‘ Allow to use "..." in more configuration options to access the defaults:
      0๏ธโƒฃ cache.managed/immutablePaths, module.defaultRules, optimization.minimizer
    • ๐Ÿฑ assets now use a content hash instead of the module hash
    • ๐Ÿ‘Œ improved the experiments.mjs to mirror node.js behavior
      • type: "module"
      • *.cjs and *.mjs
      • data:text/javascript and data:application/javascript
      • Disallow not fully specified requests in imports from these types
    • โž• add Rule.descriptionData to allow matching data from the package.json
    • โž• add support for parsing and evaluating ?? expressions
    • โž• add entry[x].runtime option to set runtimeChunk set entry
    • optimization.usedExports now analyses used exports separately per runtime to allow independent optimization
      • add "global" option to optimization.usedExports analyse used exports globally instead (faster)
    • โšก๏ธ optimization.concatenateModules now optimizes per runtime when analysed by optimization.usedExports
    • โž• add splitChunks.usedExports resp. splitChunks.cacheGroups[x].usedExports to compare modules based on used exports or ignore them while comparing
      • This is relevant when looking for shared module to combine them in a chunk. When enabled modules will only be considered as equal when used exports match.
      • false is usually better for long term caching and a smaller total size
      • true is usually better for load performance of individual pages.
      • This is enabled by default in production mode.
    • โž• add optimization.mangleExports: "size" to optimize export names for minimal size
    • give useful error message when using runtime or dependOn incorrectly in entry
    • ๐Ÿ‘Œ improve --progress and --progress --profile output
    • ๐Ÿ— store build dependencies and store cache after finishing the compilation in watch mode to avoid adding extra delay

    ๐Ÿ”„ Changes

    • 0๏ธโƒฃ splitChunks.minSize defaults to 20k in production
    • 0๏ธโƒฃ splitChunks.enforceSizeThreshold defaults to 50k in production
    • ๐Ÿ—„ using compilation.cache directly is now deprecated
    • ๐Ÿ—„ deprecate optimization.noEmitOnErrors in favor of optimization.emitOnErrors
      • negative flags can be confusing

    ๐Ÿ›  Bugfixes

    • ๐Ÿ‘Œ improve the merging of resolve options to apply byDependency in the correct order as specified
    • calling compiler.close multiple times will still call all callbacks correctly
    • Compiler.hooks.invalid will now also be triggered when manually invalidating the watching
    • ๐Ÿ›  fix passing externalsType via configuration
    • โž• add webpack-cli as optional peer dependency to allow using it with Yarn 2
    • ๐Ÿ›  fix display for built time in stats at 10 o'clock
  • v5.0.0-beta.22 Changes

    July 09, 2020

    ๐Ÿ”‹ Features

    • ๐Ÿฑ throw error when trying to emit assets that only differ in casing
    • โž• add watchFileSystem to MultiCompiler
    • avoid tracking exports usage information for non-statically analyzable modules
    • ๐Ÿ— do not show harmony linking warnings/errors (export not found) when the imported module already has build errors

    ๐Ÿ›  Bugfixes

    • ๐Ÿ– handle snapshot creation failure in resolver cache
    • [Cli] fix conversion from string to number arguments
    • ๐Ÿ— use different approach of elimination build cycles in HotModuleReplacementPlugin
    • [Module Federation] providing modules do no override already loaded shared modules in the same version

    ๐Ÿ”„ Changes

    • do no track exports usage information in development

    Removals

    • โœ‚ remove ability to modify the compilation hash after the hash has been created
    • โœ‚ remove HotModuleReplacementPlugin multiStep mode
  • v5.0.0-beta.21 Changes

    July 06, 2020

    ๐Ÿ”‹ Features

    • ๐Ÿ‘ export * as X from "..." is now supported
    • ๐Ÿ‘ webpack now better understand URLs
      • add support for file: URLs
      • add support for fragments #fragment
      • add new hooks to allow plugins to add custom schemes
    • โž• add support for import.meta
      • import.meta.webpackHot is the HMR API for ESM
      • import.meta.webpack is the webpack major version
      • import.meta.url is the file: url of the current file
    • Module Federation
      • add complete SemVer ranges support (e. g. >=1 <4 || >5 <=7 || 3.4.X || 3.5.0-beta)
      • choose shared version deterministic by uniqueName for better caching
      • remove ability to pass version or requiredVersion as array (only strings are supported)
      • Container API changed: Share Scope format is different now

    ๐Ÿ›  Bugfixes

    • ๐Ÿ‘Œ improve compat layer for MainTemplate and Module.source() to support more webpack 4 plugins
    • Module Federation
      • fix a crash when two runtimes try to remove a script tag
      • make bundles more deterministic to avoid random changes
  • v5.0.0-beta.20 Changes

    June 29, 2020

    ๐Ÿ›  Bugfixes

    • โœ‚ Remove broken postinstall script