0.1.0 • Published 8 years ago

custom-properties-sass v0.1.0

Weekly downloads
2
License
MIT
Repository
github
Last release
8 years ago

custom-properties-sass Build Status

Transpile Custom Properties to Sass variables

Installation

$ npm install custom-properties-sass

Example

Input:

:root {
  --red: #ff4136;
  --green: #2ecc40;
  --blue: #0074d9;
}

Output:

$red: #ff4136;
$green: #2ecc40;
$blue: #0074d9;

Usage

// dependencies
var fs = require("fs")
var postcss = require("postcss")
var customPropertieSass = require("custom-propertie-sass")

// css to be processed
var css = fs.readFileSync("input.css", "utf8")

// process css
var output = postcss()
  .use(customPropertieSass())
  .process(css)
  .css

License

The MIT License (MIT)

Copyright (c) 2016 Masaaki Morishita