{"id":20742,"library":"webpack-defaults","title":"webpack-defaults","description":"Tooling to synchronize boilerplate configurations and project scaffolding across webpack ecosystem projects. Current stable version is v6.3.0 (December 2019) with irregular release cadence (multiple minor releases per month). Key differentiators: it is the official webpack-contrib scaffolding tool, providing a single source of truth for CI, linting, testing, and npm scripts. Alternatives like create-react-app or vue-cli are more opinionated for specific frameworks. Requires webpack ^4.3.0 as peer dependency. Last release v6.3.0; development appears stalled since late 2019.","status":"maintenance","version":"4.0.0","language":"javascript","source_language":"en","source_url":"https://github.com/webpack-contrib/webpack-defaults","tags":["javascript","webpack"],"install":[{"cmd":"npm install webpack-defaults","lang":"bash","label":"npm"},{"cmd":"yarn add webpack-defaults","lang":"bash","label":"yarn"},{"cmd":"pnpm add webpack-defaults","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"peer dependency: required to scaffold webpack projects","package":"webpack","optional":false}],"imports":[{"note":"Package is ESM-only; no CommonJS support. Named exports may not exist.","wrong":"const defaults = require('@webpack-contrib/defaults')","symbol":"defaults","correct":"import defaults from '@webpack-contrib/defaults'"},{"note":"If runDefaults is exported; check documentation. CJS require may return undefined.","wrong":"const runDefaults = require('@webpack-contrib/defaults').runDefaults","symbol":"runDefaults","correct":"import { runDefaults } from '@webpack-contrib/defaults'"},{"note":"Do not try to import from subpath; all exports are from main entry.","wrong":"const config = require('@webpack-contrib/defaults/config')","symbol":"config","correct":"import { config } from '@webpack-contrib/defaults'"}],"quickstart":{"code":"npm install @webpack-contrib/defaults --save-dev\n# After install, add a script to package.json manually or run:\nnpm run defaults\n# The 'defaults' npm script is automatically added to your package.json during install.\n# To sync configurations:\nnode -e \"import('@webpack-contrib/defaults').then(m => m.runDefaults())\"","lang":"typescript","description":"Shows install and execution of the defaults command to sync webpack project boilerplate configurations."},"warnings":[{"fix":"Upgrade Node.js to version 10.13.0 or higher.","message":"Node.js >=10.13.0 required as of v6.0.0","severity":"breaking","affected_versions":">=6.0.0"},{"fix":"Use webpack^4.3.0. For webpack 5, consider alternative scaffolding.","message":"Support for webpack@5 dropped in v6.0.0","severity":"breaking","affected_versions":">=6.0.0"},{"fix":"Consider using a different scaffolding tool or forking the repo.","message":"Package is no longer actively maintained; last release December 2019","severity":"deprecated","affected_versions":">=0.0.0"},{"fix":"Commit CI config changes manually; or disable auto-sync by removing the defaults script.","message":"CI configuration may be overwritten on each 'npm run defaults'","severity":"gotcha","affected_versions":">=0.0.0"},{"fix":"Use npm install @webpack-contrib/defaults --save-dev","message":"Installing from npm requires @webpack-contrib/defaults scope; not webpack-defaults","severity":"gotcha","affected_versions":">=0.0.0"}],"env_vars":null,"last_verified":"2026-04-25T00:00:00.000Z","next_check":"2026-07-24T00:00:00.000Z","problems":[{"fix":"Use dynamic import: import('@webpack-contrib/defaults').then(m => m.runDefaults())","cause":"Package is ESM-only but tried to import via CommonJS require()","error":"Error [ERR_REQUIRE_ESM]: require() of ES Module /path/to/node_modules/@webpack-contrib/defaults/index.js not supported."},{"fix":"Ensure package name in import/require is '@webpack-contrib/defaults'","cause":"Package name is scoped; webpack-defaults is the unscoped name but the published package is @webpack-contrib/defaults","error":"Module not found: Can't resolve '@webpack-contrib/defaults'","affected_versions":">=6.0.0"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}