1.0.1 • Published 7 years ago

postcss-clear-fix v1.0.1

Weekly downloads
3
License
MIT
Repository
github
Last release
7 years ago

A PostCSS plugin to add clearfix in one line.

Installation

npm install postcss-clear-fix

Example

div.container {
    clear: fix
}

will produce

div.container:after { 
    content: " "; 
    display: table; 
    clear: both
}

Usage

Using Gulp.

var gulp            = require('gulp'),
    postcss         = require('gulp-postcss'),
    clearfix        = require('postcss-clear-fix');

gulp.task('css', function() {
    gulp.src('path/to/dev/css').
        .pipe(postcss({
            // use it after nesting plugins
            clearfix
        }))
        .pipe(gulp.dest('path/to/build/css'));
});

// rest of the gulp file