A minimal, lightweight CLI for webpack that focuses on configuration file use, allowing unlimited custom command-line flags via the webpack-nano/argv export. Current stable version is 1.1.1. It is maintained as a smaller alternative to webpack-cli, roughly 90% smaller. Supports config files in Babel, ES6, TypeScript, and ESM formats with appropriate loaders. Drops Node <10 support since v0.7.0 and includes breaking changes in v1.0.0 due to yargs-parser update affecting parsed argv output.
npm install webpack-nanoVerified import paths — ran on the pinned version, not inferred.
Install webpack-nano with webpack, create a basic config, and run a build using the wp CLI.
Review usage of 'webpack-nano/argv' output; ensure custom flags parse as expected under the new parser.
Use Node v10 or higher.
If relying on previous behavior, explicitly set `stats.colors: false` and `stats.exclude: undefined` in webpack config.
Use `npx wp` instead of `npx webpack`.
Use `import { argv } from 'webpack-nano/argv'` or `const argv = require('webpack-nano/argv')`.Run `npm install webpack --save-dev` alongside webpack-nano.
Ensure you are using `require('webpack-nano/argv')` or `import { argv } from 'webpack-nano/argv'`. Requires webpack-nano >=0.5.0.Use the correct subpath: `const argv = require('webpack-nano/argv')`