1.0.0 • Published 8 years ago
gulp-css-remove-attributes v1.0.0
gulp-css-remove-attributes
Remove CSS attributes from stylesheets that you do not have full control.
It is useful to completly remove styles from libraries like Bootstrap and Semantic UI instead of having to overwrite them with custom CSS.
Install
$ npm install --save-dev gulp-css-remove-attributesUsage
var gulp = require('gulp');
var removeAttributes = require('gulp-css-remove-attributes')
// in this example the box-shadow and text-transform attributes will not be
// present in the generated CSS file
gulp.task('default', function () {
return gulp.src('src/*.css')
.pipe(removeAttributes(['box-shadow', 'text-transform'], {compress: true}))
.pipe(gulp.dest('dist'));
});Documentation
removeAttributes(attributes, options)
attributes
Type:
arrayCSS attributes that should be removed from the input files.
options
Type:
objectOptions that are forwarded to css library.
Probably only
compressandindentoptions will be useful in the context of this plugin.
1.0.0
8 years ago