webpack-bundler

raw JSON →
0.1.0-alpha.1 verified Sat Apr 25 auth: no javascript deprecated

An experimental alpha package providing webpack bundling flow and proxy-mock functionality for development. Version 0.1.0-alpha.1 is pre-release with no stable release yet. It depends on webpack ^3.0.0. Key differentiators: integrates proxy mocking directly into the bundling pipeline, but is early-stage and likely unstable. Not recommended for production use.

error Cannot find module 'webpack-bundler'
cause Package not installed or name mistyped.
fix
npm install webpack-bundler
error Error: webpack version mismatch; expected ^3.0.0
cause Incompatible webpack version installed.
fix
npm install webpack@3
error TypeError: webpackBundler is not a function
cause Incorrect import (e.g., using require in ESM context).
fix
Use import syntax as shown in docs.
breaking Alpha version may have incomplete APIs and breaking changes between releases.
fix Lock to exact version and expect migration.
deprecated Package is unlikely maintained; no updates since initial alpha.
fix Consider alternatives like webpack-dev-server with proxy.
gotcha Requires webpack ^3.0.0, not compatible with webpack 4 or 5.
fix If using newer webpack, do not use this package.
npm install webpack-bundler
yarn add webpack-bundler
pnpm add webpack-bundler

Shows basic usage of webpack-bundler with proxyMock integration.

import webpackBundler from 'webpack-bundler';
import { proxyMock } from 'webpack-bundler';

const config = {
  entry: './src/index.js',
  output: { path: './dist', filename: 'bundle.js' },
  proxy: proxyMock({ '/api': 'http://localhost:3000' })
};

webpackBundler(config, (err, stats) => {
  if (err) console.error(err);
  else console.log(stats.toString());
});