postcss-atroot
Advanced tools
Comparing version 0.1.0 to 0.1.2
{ | ||
"name": "postcss-atroot", | ||
"version": "0.1.0", | ||
"version": "0.1.2", | ||
"description": "PostCSS plugin to place rules directly at the root", | ||
@@ -8,3 +8,3 @@ "main": "index.js", | ||
"type": "git", | ||
"url": "https://github.com/OEvgeny/postcss-atroot.git" | ||
"url": "https://github.com/OEvgeny/postcss-atroot.git" | ||
}, | ||
@@ -11,0 +11,0 @@ "scripts": { |
@@ -19,11 +19,37 @@ # PostCSS at-root [![Circle CI](https://circleci.com/gh/OEvgeny/postcss-atroot.svg?style=svg)](https://circleci.com/gh/OEvgeny/postcss-atroot) | ||
It will play well also with ``@include``, and may be very useful when developing css frameworks. | ||
It will play well with postcss ``@include`` plugins. | ||
foo.css: | ||
```css | ||
@at-root { | ||
@viewport { width: device-width; } | ||
} | ||
.foo { | ||
color: blue; | ||
} | ||
``` | ||
bar.css: | ||
```css | ||
.bar { | ||
@import "foo.css"; | ||
} | ||
``` | ||
Will produce: | ||
```css | ||
@viewport { width: device-width; } | ||
.bar .foo { | ||
color: blue; | ||
} | ||
``` | ||
## Usage | ||
```js | ||
postcss([ require('postcss-atroot') ]) | ||
postcss([ require('postcss-atroot')() ]) | ||
``` | ||
See [PostCSS] docs for examples for your environment. | ||
[PostCSS]: https://github.com/postcss/postcss |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
9447
55