Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/joshgillies/postcss-mysource-path
PostCSS plugin for rewriting url() paths to `mysource_files`.
https://github.com/joshgillies/postcss-mysource-path
Last synced: 5 days ago
JSON representation
PostCSS plugin for rewriting url() paths to `mysource_files`.
- Host: GitHub
- URL: https://github.com/joshgillies/postcss-mysource-path
- Owner: joshgillies
- License: mit
- Created: 2015-08-12T07:31:40.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2015-08-21T02:56:10.000Z (about 9 years ago)
- Last Synced: 2024-10-19T00:15:19.761Z (27 days ago)
- Language: JavaScript
- Size: 152 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# postcss-mysource-path
[![Build Status][travis-image]][travis-link]
[![js-standard-style][standard-image]][standard-link][travis-image]: https://travis-ci.org/joshgillies/postcss-mysource-path.svg?branch=master
[travis-link]: https://travis-ci.org/joshgillies/postcss-mysource-path
[standard-image]: https://img.shields.io/badge/code%20style-standard-brightgreen.svg?style=flat
[standard-link]: https://github.com/feross/standard> PostCSS plugin for rewriting url() paths to `mysource_files`.
## Install
`npm install postcss-mysource-path`
## Example
```js
var fs = require('fs')
var postcss = require('postcss')
var mySourcePath = require('postcss-mysource-path')var source = fs.readFileSync('input.css', 'utf8')
var output = postcss([mySourcePath()])
.process(source, {
from: 'src/stylesheet/index.css',
to: 'dist/index.css'
})
.then(function (result) {
result.messages.forEach(function (message) {
console.log(message.path)
})
})
.css
```## API
## License
MIT