Skip to content

fisx-suite/fis3-optimizer-css-compressor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

fis3-optimizer-css-compressor

Dependency Status devDependency Status NPM Version

An optimizer for fis3 to compress css files by using clean-css.

Notice: The version 0.1.x using clean-css 3.x version, thus the latest version 0.2.x using clean-css 4.x version.

The version 0.1.x has the following default config:

{
    advanced: false,
    aggressiveMerging: false,
    shorthandCompacting: false,
    compatibility: 'ie7',
    keepBreaks: true,
    relativeTo: file.dirname
}

The version 0.2.x has the following default config:

{
    compatibility: 'ie8',
    rebaseTo: file.dirname
}

How to use

Install

npm install fis3-optimizer-css-compressor -g

Add configure to fis-conf.js

fis.media('prod').match('*.css', {
    optimizer: 'css-compressor'
});

Custom compress options:

fis.match('*.css', {
       optimizer: fis.plugin('css-compressor', {
            advanced: true
       })
   });

Available options, please refer to clean-css.

About

An optimizer for fis3 to compress css files

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published