postcss-greyscale
v1.0.0
Published
A PostCSS plugin to get the greyscale equivalent of a color
Downloads
10
Maintainers
Readme
PostCSS Greyscale
A PostCSS plugin to get the greyscale equivalent of a color
Installation
npm install postcss-greyscale
Examples
/* input */
div { color: greyscale(#34bbed) }
/* output */
div { color: #9f9f9f }
Usage
Postcss JS API
postcss([require('postcss-greyscale')]).process(yourCSS);
Gulp
const gulp = require('gulp');
const postcss = require('gulp-postcss');
const greyscale = require('postcss-greyscale');
gulp.task('css', () => {
gulp.src('path/to/dev/css')
.pipe(postcss([
greyscale()
]))
.pipe(gulp.dest('path/to/build/css'));
});
Tests
npm test
License
This project is licensed under the MIT License.