2

如标题所述,当我尝试

npm install gulp-imagemin

它抛出这些错误:

npm WARN optional dep failed, continuing imagemin-gifsicle@1.0.0
npm WARN optional dep failed, continuing imagemin-pngquant@1.0.2
npm WARN optional dep failed, continuing imagemin-jpegtran@1.0.0
npm WARN optional dep failed, continuing imagemin-optipng@1.0.0
gulp-imagemin@1.0.1 node_modules/gulp-imagemin
├── object-assign@1.0.0
├── pretty-bytes@1.0.1 (get-stdin@1.0.0)
├── chalk@0.5.1 (escape-string-regexp@1.0.2, ansi-styles@1.1.0, supports-color@0.2.0,     has-ansi@0.1.0, strip-ansi@0.3.0)
├── through2@0.6.2 (xtend@4.0.0, readable-stream@1.0.32)
├── gulp-util@3.0.1 (lodash._reinterpolate@2.4.1, dateformat@1.0.8, minimist@1.1.0, lodash@2.4.1, vinyl@0.4.3, multipipe@0.1.1, lodash.template@2.4.1)
└── imagemin@1.0.5 (get-stdin@3.0.0, stat-mode@0.2.0, ware@0.3.0, tempfile@1.0.0, nopt@3.0.1, fs-extra@0.11.1, imagemin-svgo@1.0.2)

而且这个插件也不能用了,有谁知道怎么回事?谢谢。

如果这很重要,我在 OSX Mavericks。

4

1 回答 1

2

Image-min 依赖项安装失败。单独安装包将解决问题:

npm install imagemin-gifsicle imagemin-pngquant imagemin-optipng imagemin-jpegtran --save-dev
于 2014-11-25T20:04:55.103 回答