{"id":19390,"library":"broccoli-webpack","title":"broccoli-webpack","description":"Broccoli plugin for webpack v1 (now legacy). Version 1.0.0 is the latest stable release, last updated in 2015 and effectively abandoned. It wraps webpack as a Broccoli plugin, allowing Broccoli builds to bundle with webpack. Automatically sets context and output.path. No longer maintained; alternatives include broccoli-webpack2 or ember-cli for modern projects.","status":"abandoned","version":"1.0.0","language":"javascript","source_language":"en","source_url":"https://github.com/myfreeweb/broccoli-webpack","tags":["javascript","broccoli-plugin","broccoli","webpack"],"install":[{"cmd":"npm install broccoli-webpack","lang":"bash","label":"npm"},{"cmd":"yarn add broccoli-webpack","lang":"bash","label":"yarn"},{"cmd":"pnpm add broccoli-webpack","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"peer dependency: Broccoli build system required","package":"broccoli","optional":true},{"reason":"peer dependency: webpack v1 (not v2+) required","package":"webpack","optional":true}],"imports":[{"note":"CommonJS only; no ESM support.","symbol":"WebpackWriter","correct":"const WebpackWriter = require('broccoli-webpack')"},{"note":"inputNodes must be an array, even for a single tree.","wrong":"new WebpackWriter('src', { entry: './main' })","symbol":"new WebpackWriter(inputNodes, config)","correct":"var bundle = new WebpackWriter(['src'], { entry: './main' })"},{"note":"instance method, not static.","wrong":"WebpackWriter.build()","symbol":"WebpackWriter.prototype","correct":"const writer = new WebpackWriter(...); writer.build()"}],"quickstart":{"code":"var WebpackWriter = require('broccoli-webpack');\nvar js_bundler = new WebpackWriter(['src'], {\n  entry: './main',\n  output: { filename: 'app.js' },\n  externals: { 'react': 'React', 'jquery': '$' },\n  devtool: 'source-map',\n  module: {\n    preLoaders: [\n      { test: /\\.js$/, loader: 'source-map-loader' }\n    ]\n  }\n});\nmodule.exports = js_bundler;","lang":"javascript","description":"Creates a Broccoli tree that bundles JavaScript with webpack (v1) from the 'src' directory."},"warnings":[{"fix":"Use broccoli-webpack2 for webpack 2+ or switch to ember-auto-import.","message":"Package uses webpack v1 API (preLoaders, output.filename only). Does not support webpack v2+ configuration (rules, plugins).","severity":"deprecated","affected_versions":"1.0.0"},{"fix":"Wrap single tree in an array: new WebpackWriter([tree], config).","message":"inputNodes must be an array, even if passing a single tree.","severity":"gotcha","affected_versions":">=0.0.0"},{"fix":"Specify plugins in config as usual, but some may not work due to Broccoli tree isolation.","message":"Does not support webpack plugins properly; may require workarounds.","severity":"gotcha","affected_versions":"1.0.0"},{"fix":"Use a maintained alternative like broccoli-webpack2 or ember-cli.","message":"The plugin stopped receiving updates in 2015. It is not compatible with modern Node versions or webpack 2+.","severity":"breaking","affected_versions":"1.0.0"}],"env_vars":null,"last_verified":"2026-04-25T00:00:00.000Z","next_check":"2026-07-24T00:00:00.000Z","problems":[{"fix":"Run 'npm install --save-dev broccoli-webpack'","cause":"Package not installed or not in node_modules.","error":"Error: Cannot find module 'broccoli-webpack'"},{"fix":"Wrap input in an array: new WebpackWriter([inputNode], config)","cause":"Passed a single string instead of an array.","error":"TypeError: inputNodes is not iterable"},{"fix":"Use webpack v1 config format (loaders, preLoaders) or upgrade to broccoli-webpack2.","cause":"Using webpack v2+ config (e.g., 'rules' instead of 'loaders').","error":"Invalid configuration object. Webpack has been initialised using a configuration object that does not match the API schema."}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}