Search code examples
sassgulpminify

Gulp minify CSS delete expression


The following line from my icomoon font scss will be deleted by gulp 'minify-css' task

.icon-home {
    *zoom: expression(this.runtimeStyle['zoom'] = '1', this.innerHTML = '');
}

how to avoid deleting the ie expression fix?


Solution

  • The problem is not the expression, is the "*". Try removing it:

    .icon-home {
        zoom: expression(this.runtimeStyle['zoom'] = '1', this.innerHTML = '');
    }
    

    I think it's not a solution, you can try the compatibility option of gulp-minify-css and set it to IE7 for example.