{"id":20730,"library":"webpack-config-dump-plugin","title":"Webpack Config Dump Plugin","description":"A webpack plugin (v3.0.3, stable, low activity) that writes the resolved/compiled webpack configuration to a file on disk. Useful for debugging dynamic resolve aliases or making them visible to IDEs. Key differentiators: supports circular reference handling, configurable depth, and optional inclusion of function names and falsey values. Competing with webpack-merge's logging or custom config debugging but purpose-built for file output.","status":"active","version":"3.0.3","language":"javascript","source_language":"en","source_url":"https://github.com/n0th1ng-else/webpack-config-dump-plugin","tags":["javascript","webpack","plugin","dump","config","typescript"],"install":[{"cmd":"npm install webpack-config-dump-plugin","lang":"bash","label":"npm"},{"cmd":"yarn add webpack-config-dump-plugin","lang":"bash","label":"yarn"},{"cmd":"pnpm add webpack-config-dump-plugin","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"peer dependency; plugin hooks into webpack build lifecycle","package":"webpack","optional":false}],"imports":[{"note":"Named export only; default export is not available.","wrong":"import WebpackConfigDumpPlugin from 'webpack-config-dump-plugin'","symbol":"WebpackConfigDumpPlugin","correct":"import { WebpackConfigDumpPlugin } from 'webpack-config-dump-plugin'"},{"note":"CJS destructured require works; direct assignment gives undefined.","wrong":"const WebpackConfigDumpPlugin = require('webpack-config-dump-plugin')","symbol":"WebpackConfigDumpPlugin","correct":"const { WebpackConfigDumpPlugin } = require('webpack-config-dump-plugin')"},{"note":"No .default export; this pattern would give undefined.","wrong":"const WebpackConfigDumpPlugin = require('webpack-config-dump-plugin').default","symbol":"WebpackConfigDumpPlugin","correct":"import { WebpackConfigDumpPlugin } from 'webpack-config-dump-plugin'"}],"quickstart":{"code":"// webpack.config.js\nconst { WebpackConfigDumpPlugin } = require('webpack-config-dump-plugin');\nconst path = require('path');\n\nmodule.exports = {\n  entry: './src/index.js',\n  output: {\n    path: path.resolve(__dirname, 'dist'),\n    filename: 'bundle.js',\n  },\n  plugins: [\n    new WebpackConfigDumpPlugin({\n      outputPath: './config-dumps',\n      name: 'my-config.dump',\n      depth: 4,\n      keepCircularReferences: false,\n      showFunctionNames: true,\n      includeFalseValues: false,\n    }),\n  ],\n};","lang":"javascript","description":"Shows a minimal webpack config using the plugin with all available options to dump the resolved configuration."},"warnings":[{"fix":"Set includeFalseValues: true if you need the old behavior.","message":"Version 3 changed default behavior: empty objects and arrays are now excluded by default.","severity":"breaking","affected_versions":">=3.0.0"},{"fix":"Use const { WebpackConfigDumpPlugin } = require('webpack-config-dump-plugin').","message":"Version 2 switched to ES module import – CJS require must be destructured.","severity":"breaking","affected_versions":">=2.0.0 <3.0.0"},{"fix":"Use keepCircularReferences: true to dump entire config and ignore depth.","message":"depth option may be removed in future versions; keepCircularReferences overrides it.","severity":"deprecated","affected_versions":">=3.0.0"},{"fix":"Don't rely on depth when keepCircularReferences is true.","message":"If you set keepCircularReferences: true, the depth option is ignored.","severity":"gotcha","affected_versions":">=3.0.0"}],"env_vars":null,"last_verified":"2026-04-25T00:00:00.000Z","next_check":"2026-07-24T00:00:00.000Z","problems":[{"fix":"Use import { WebpackConfigDumpPlugin } from 'webpack-config-dump-plugin' or const { WebpackConfigDumpPlugin } = require(...)","cause":"Importing default export instead of named export.","error":"TypeError: webpackConfigDumpPlugin is not a constructor"},{"fix":"Install webpack: npm install webpack --save-dev","cause":"Missing webpack peer dependency.","error":"Module not found: Error: Can't resolve 'webpack' in ..."},{"fix":"Increase depth or set keepCircularReferences: true.","cause":"Dumping a non-object config entry (e.g., function) due to depth limit.","error":"Cannot read property 'length' of undefined"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}