npm install --save-dev webpack
npm install --save-dev webpack # or specific version npm install --save-dev webpack@<version>
npm install --save-dev webpack-cli
$ composer require symfony/webpack-encore-bundle $ yarn install
yarn add webpack --dev
npm i npm-install-webpack-plugin