gulp-replace-important
Gulp plugin for replace-important. Plugin for removing !important from css rules from selectors and replacing them inside similar selectors - the new selectors will have the highest specificity in the CSS file. This is useful for making CSS Supported by AMPHTML. This plugin only supports Buffers, but stream support could be added with gulp-streamify.
Installation
As a dev dependency to your project
npm install --save-dev gulp-replace-important
Usage
const gulp = ;const gulpReplaceImportant = ; /*** Example:* Input: body {background-color: red !important;}** Output: body {}:root:not(#FK_ID) body{background-color: red }*/gulp;
Tests
Tests can be run with:
npm run test
Contributing
Please see the CONTRIBUTING.md