rework-import-external

0.0.4 • Public • Published

rework-import-external Build Status

A rework plugin to download and inline CSS for external source via @import

Install

$ npm install --save rework-import-external

Usage

const rework = require('rework');
const plugin = require('rework-import-external');

let css = rework(`
@import "style1.css" (min-width: 100px);
@import "/root/path/style2.css";
@import "../style3.css";
`, {
  // base URL
  source: 'http://some.domain/base/path/'
}).use(plugin({}, (err, ast) => {
  css.toString()
}))

License

MIT © Andriy Rakhnin

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.0.4
    0
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.0.4
    0
  • 0.0.3
    0
  • 0.0.2
    0
  • 0.0.1
    0

Package Sidebar

Install

npm i rework-import-external

Weekly Downloads

0

Version

0.0.4

License

MIT

Last publish

Collaborators

  • rakhnin