🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more →

postcss-css-variables

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

postcss-css-variables - npm Package Compare versions

Comparing version

to
0.2.3

# 0.2.3 - 2015-5-4
- Add support for CSS4 descendant selector `>>` syntax
# 0.2.2 - 2015-5-1

@@ -4,0 +9,0 @@

// PostCSS CSS Variables (postcss-css-variables)
// v0.2.2
// v0.2.3
//

@@ -69,3 +69,7 @@ // https://github.com/MadLittleMods/postcss-css-variables

.map(function(piece) {
return piece.trim();
// Trim whitespace which would be a normal descendant selector
// and trim off the CSS4 descendant `>>` into a normal descendant selector
return piece.trim().replace(/\s*?>>\s*?/, function(match) {
return '';
});
});

@@ -72,0 +76,0 @@

{
"name": "postcss-css-variables",
"version": "0.2.2",
"version": "0.2.3",
"description": "PostCSS plugin to transform CSS Custom Properties(CSS variables) syntax into a static representation",

@@ -5,0 +5,0 @@ "keywords": [

@@ -0,1 +1,3 @@

[![npm version](https://badge.fury.io/js/postcss-css-variables.svg)](http://badge.fury.io/js/postcss-css-variables) [![Build Status](https://travis-ci.org/MadLittleMods/postcss-css-variables.svg)](https://travis-ci.org/MadLittleMods/postcss-css-variables)
# PostCSS CSS Variables

@@ -9,8 +11,19 @@

## Latest Version: 0.2.2
## Latest Version: 0.2.3
### [Changelog](https://github.com/MadLittleMods/postcss-css-variables/blob/master/CHANGELOG.md)
### Install
`npm install postcss-css-variables --save-dev`
# [Code Playground](https://madlittlemods.github.io/postcss-css-variables/playground/)
[Try it](https://madlittlemods.github.io/postcss-css-variables/playground/) before you install it!
Add some PostCSS and it will show you the transformed/compiled CSS.
# Usage
You can try any of these examples on the [code playground](https://madlittlemods.github.io/postcss-css-variables/playground/).
```

@@ -89,6 +102,6 @@ var postcss = require('postcss');

var output = postcss([
// Process any CSS variables
cssvariables(/*options*/),
// After we processed all of the variables, flatten/unnest rules
nestedcss
// Flatten/unnest rules
nestedcss,
// Then process any CSS variables
cssvariables(/*options*/)
])

@@ -95,0 +108,0 @@ .process(mycss)

Sorry, the diff of this file is not supported yet