What is the difference installing between the two? I installed webpack globally as said on the installation page then I moved to getting started it is said there to install webpack-cli locally. CLI = Command Line Interface, Does that mean webpack do not have cli so that I have to install webpack-cli?
1 Answer
Since webpack version 4, the command line interface got removed from the main package and added to its own repo and package.
You are obliged to install a cli aside of webpack. CLI = command line interface, webpack = main functionalities.
-
1Right, I faced an issue where we after 1 year upgraded the webpack version from 2.6.1 to 4.29.0 and CLI commands like
node node_modules/webpack/bin/webpack.js --env.prod
stopped working and then I installed webpack-cli and it started working again. Jan 31, 2019 at 10:45 -
5does anyone know why two separate packages are created instead of one single package? Dec 8, 2019 at 13:21
-
1You upgraded 2 major versions at once and are surprised something broke, @JagjitSingh? Sep 1, 2020 at 6:55