
Security News
Meet Socket at Black Hat Europe and BSides London 2025
Socket is heading to London! Stop by our booth or schedule a meeting to see what we've been working on.
gulp-sakugawa
Advanced tools
Run
sakugawavia gulp, for CSS splitting, filtering and organising.

Internet Explorer versions from 6 up to 9 come with a limitation for selectors present in a single CSS file. This limitation of 4095 selectors created the need for CSS splitter, which might be the main use case of this task runner plugin.
Since IE8 and earlier, do not support media queries, but IE9 does, there is an option for handling media queries differently, based on the targeted IE version. By separating media queries in to a different file, it will allow the to include that CSS file conditionally only when IE9 is being used. Ideally this would reduce the amount of bytes downloaded by IE8, which cannot handle the media queries anyhow, and thus prevent downloading something that is not even used.
Internally this gulp task uses sakugawa, thus in the case of any problems regarding the
resulting output or input handling, and also for any feature requests, please refer to the
issues at Sakugawa project.
Please note that Node.js version minimum of 10.13.0, which is the active Long Term Support (LTS) version, is required to use this plugin.
npm install gulp-sakugawa --save-dev
const gulpSakugawa = require('gulp-sakugawa');
Example configuration against Pure CSS,
which results in two files, pure-min_1.css and pure-min_2.css in which the latter
contains all media queries.
const gulp = require('gulp'),
gulpSakugawa = require('gulp-sakugawa');
gulp.task('default', function() {
gulp.src('pure-min.css')
.pipe(gulpSakugawa({
maxSelectors: 400,
mediaQueries: 'separate',
suffix: '_'
}))
.pipe(gulp.dest('.'));
});
The CSS file used in the example can be retrieved with:
wget http://yui.yahooapis.com/pure/0.5.0/pure-min.css
"A Beginner's Guide to Open Source: The Best Advice for Making your First Contribution".
Also there is a blog post about "45 Github Issues Dos and Don’ts".
Linting is done with ESLint and can be executed with npm run lint.
There should be no errors appearing after any JavaScript file changes.
v0.7.0 (2020-05-29)
6.9.5 to 10.13.0v0.6.0 (2017-06-28)
4.2.0 to 6.9.5v0.5.1 (2016-08-24)
v0.5.0 (2016-05-13)
4.2.0 (LTS)sakugawa is v0.5.0v0.4.1 (2015-09-03)
v0.4.0 (2015-03-11)
v0.4.0 which preserves existing @charset rules to all resulting filesv0.3.0 (2015-02-23)
v0.3.0 which adds the minSheets optionv0.2.0 (2014-11-19)
Copyright (c) Juga Paazmaya paazmaya@yahoo.com
Licensed under the MIT license.
FAQs
Run Sakugawa via gulp for CSS splitting, filtering and organising
The npm package gulp-sakugawa receives a total of 190 weekly downloads. As such, gulp-sakugawa popularity was classified as not popular.
We found that gulp-sakugawa demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Socket is heading to London! Stop by our booth or schedule a meeting to see what we've been working on.

Security News
OWASP’s 2025 Top 10 introduces Software Supply Chain Failures as a new category, reflecting rising concern over dependency and build system risks.

Research
/Security News
Socket researchers discovered nine malicious NuGet packages that use time-delayed payloads to crash applications and corrupt industrial control systems.