Combine matching media queries into one media query definition. Useful for CSS generated by preprocessors using nested media queries.
This plugin requires Grunt
If you haven't used Grunt before, be sure to check out the Getting Started guide, as it explains how to create a Gruntfile as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command:
npm install grunt-combine-mq --save-dev
The 'combine_mq' task
In your project's Gruntfile, add a section named
combine_mq to the data object passed into
In this example, the default options are used to do combine media queries in all
.css files in the
src directory and outputs them to the
In this example, the custom options are used to do combine media queries in the
test.css files in the
src directory and outputs to the
dist directory with a new filename -
To contribute check the GitHub issues then work away!
In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using Grunt.
- Install editorconfig-sublime for Sublime Text to help with consistent code formatting.
- Commit messages loosely adhere to these guidelines.
- Versioning adheres to Semver.
- 11-04-15 - v0.9.0 - Logs out original and processed file sizes
- 07-04-15 - v0.8.0 - Updates to Node combine-mq v0.8.0. See releases for more info.
- 22-12-14 - v0.7.0 - Updates to latest node package, adds tasks and rewrites tests for it
- 21-12-14 - v0.6.0 - Updates to Node combine-mq v0.6.0. See releases for more info.
- 21-12-14 - v0.5.0 - Updates to Node combine-mq v0.5.0. See releases for more info.
- 27-09-14 - v0.2.0 - Adds tests.
- 26-09-14 - v0.1.0 - Initial release.
See releases for more info.