{"id":20752,"library":"webpack-emit-all-plugin","title":"webpack EmitAllPlugin","description":"Webpack plugin that emits all files in the dependency tree as separate files without bundling, allowing use of webpack loaders/plugins for non-bundling tasks. Current version 2.0.1 (unreleased, API usable but unstable, no pre-release). Peer dependency on webpack >=4. Differentiators: eliminates bundling step, useful for processing assets individually while leveraging webpack's loader pipeline. Last updated 2018, no recent maintenance.","status":"maintenance","version":"2.0.1","language":"javascript","source_language":"en","source_url":"https://github.com/DrewML/webpack-emit-all-plugin","tags":["javascript","webpack","emit"],"install":[{"cmd":"npm install webpack-emit-all-plugin","lang":"bash","label":"npm"},{"cmd":"yarn add webpack-emit-all-plugin","lang":"bash","label":"yarn"},{"cmd":"pnpm add webpack-emit-all-plugin","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"peer dependency, plugin runs as webpack plugin","package":"webpack","optional":false}],"imports":[{"note":"Package does not export ESM; CJS require is required.","wrong":"import EmitAllPlugin from 'webpack-emit-all-plugin'","symbol":"EmitAllPlugin","correct":"const EmitAllPlugin = require('webpack-emit-all-plugin')"},{"note":"The plugin is exported as module.exports directly, not as named export.","wrong":"const EmitAllPlugin = require('webpack-emit-all-plugin').default","symbol":"EmitAllPlugin","correct":"const { EmitAllPlugin } = require('webpack-emit-all-plugin')"},{"note":"Must be instantiated with 'new' as it is a class.","wrong":"plugins: [EmitAllPlugin({ path: './dist' })]","symbol":"EmitAllPlugin","correct":"plugins: [new EmitAllPlugin({ path: './dist' })]"}],"quickstart":{"code":"const path = require('path');\nconst EmitAllPlugin = require('webpack-emit-all-plugin');\n\nmodule.exports = {\n  entry: './src/index.js',\n  output: { path: path.resolve(__dirname, 'dist') },\n  module: {\n    rules: [\n      { test: /\\.js$/, use: 'babel-loader' }\n    ]\n  },\n  plugins: [\n    new EmitAllPlugin({\n      ignorePattern: /node_modules/,\n      path: path.join(__dirname, 'unbundled-out')\n    })\n  ]\n};","lang":"javascript","description":"Configures webpack with EmitAllPlugin to emit all processed files individually without bundling, applying babel-loader."},"warnings":[{"fix":"Use webpack 4 or test compatibility; consider alternatives like CopyWebpackPlugin.","message":"Plugin may not work with webpack 5 due to internal API changes.","severity":"breaking","affected_versions":">=2.0.0"},{"fix":"Migrate to actively maintained plugin like copy-webpack-plugin or assets-webpack-plugin.","message":"Package has not been updated since 2018; no support for webpack 5 or newer features.","severity":"deprecated","affected_versions":">=0"},{"fix":"Always provide an ignorePattern option to exclude node_modules to avoid large output.","message":"All files in dependency tree are emitted, including node_modules unless ignored.","severity":"gotcha","affected_versions":">=0"},{"fix":"Use path.resolve or path.join with __dirname to specify absolute output path.","message":"Output path must be absolute or relative to output.path; relative paths may cause unexpected results.","severity":"breaking","affected_versions":">=0"}],"env_vars":null,"last_verified":"2026-04-25T00:00:00.000Z","next_check":"2026-07-24T00:00:00.000Z","problems":[{"fix":"Use 'new EmitAllPlugin({...})' after proper require: const EmitAllPlugin = require('webpack-emit-all-plugin');","cause":"Importing the plugin incorrectly as a default export or without 'new'.","error":"TypeError: EmitAllPlugin is not a constructor"},{"fix":"Run 'npm install -D webpack-emit-all-plugin' to install as dev dependency.","cause":"Package not installed or in devDependencies.","error":"Error: Cannot find module 'webpack-emit-all-plugin'"},{"fix":"Set absolute path using path.resolve(__dirname, 'custom-output') in plugin options.","cause":"The 'path' option may be relative or missing; defaults to webpack output.path.","error":"Output files not emitted to specified path"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}