Package Exports
- postcss-color-hex-alpha
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (postcss-color-hex-alpha) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
postcss-color-hex-alpha 
PostCSS plugin to transform W3C RGBA hexadecimal notations (#RRGGBBAA or #RGBA) to more compatible CSS (rgba()).
Installation
$ npm install postcss-color-hex-alpha
Usage
// dependencies
var fs = require("fs")
var postcss = require("postcss")
var colorHexAlpha = require("postcss-color-hex-alpha")
// css to be processed
var css = fs.readFileSync("input.css", "utf8")
// process css
var output = postcss()
.use(colorHexAlpha())
.process(css)
.css
Using this input.css
:
body {
background: #9d9c
}
you will get:
body {
background: rgba(153, 221, 153, 0.8)
}
Checkout tests for more examples.
Contributing
Work on a branch, install dev-dependencies, respect coding style & run tests before submitting a bug fix or a feature.
$ git clone https://github.com/postcss/postcss-color-hex-alpha.git
$ git checkout -b patch-1
$ npm install
$ npm test