tcoopman / image-webpack-loader

Image loader module for webpack
MIT License
2.03k stars 132 forks source link

npm install dependencies failed (verison 6.0.0) #198

Open smalldice opened 5 years ago

smalldice commented 5 years ago
WechatIMG9
anikethsaha commented 4 years ago

Can you share more details with version and commands .

NigeAtAnd commented 4 years ago

Possibly related, I've started using this loader today and get the following error on Gitlab CI:

Error: Cannot find module 'imagemin-gifsicle'
Require stack:
- /frontend/node_modules/image-webpack-loader/index.js
...

It works fine on my local box.

anikethsaha commented 4 years ago

do you have imagemin-gifsicle in your devdep or dep ?

NigeAtAnd commented 4 years ago

No, I thought this loader came bundled with the various imagemin plugins?

anikethsaha commented 4 years ago

Actually this loader has them in optionalDependencies so it never 100% assured that they will be installed if it's in optionalDependencies. Its recommended to install them as devDep