Explorar o código

Avoid destroying SVG fonts when optimizing images

Gaël Métais %!s(int64=10) %!d(string=hai) anos
pai
achega
6bd55e4807
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      lib/tools/weightChecker/imageOptimizer.js

+ 1 - 1
lib/tools/weightChecker/imageOptimizer.js

@@ -200,7 +200,7 @@ var ImageOptimizer = function() {
         } else if (type === 'png' && !lossy) {
             engine = Imagemin.optipng({optimizationLevel: OPTIPNG_COMPRESSION_LEVEL});
         } else if (type === 'svg' && !lossy) {
-            engine = Imagemin.svgo();
+            engine = Imagemin.svgo({ plugins: [ { removeUselessDefs: false } ] });
         } else {
             deferred.reject('No optimization engine found for imagemin');
         }