https://github.com/sormy/css-asset-copier
CSS asset copier for CSS URL rewriter
https://github.com/sormy/css-asset-copier
Last synced: about 1 month ago
JSON representation
CSS asset copier for CSS URL rewriter
- Host: GitHub
- URL: https://github.com/sormy/css-asset-copier
- Owner: sormy
- License: mit
- Created: 2016-10-14T03:11:26.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2016-11-03T01:45:32.000Z (over 8 years ago)
- Last Synced: 2025-03-11T02:27:36.580Z (2 months ago)
- Language: JavaScript
- Size: 15.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# CSS Asset Copier #
## Features ##
- Designed to be used with `css-url-rewriter-ex` library
- Copy CSS related local assets to target directory
- Covered by unit tests## Installation ##
```shell
npm install css-asset-copier
```## Usage ##
```javascript
var CssUrlRewriter = require('css-url-rewriter-ex');
var CssAssetCopier = require('css-asset-copier');const rewriter = new CssUrlRewriter();
const assetCopier = new CssAssetCopier('dist');rewriter.rewrite(filename, content);
assetCopier.copyAssets(rewriter.getLocalAssetList())
.then(() => {
console.log('Done!');
});
```