broccoli-resin

0.1.0 • Public • Published

broccoli-resin Build Status

Broccoli wrapped Resin - A CSS Preprocessor on top of Rework

Install

$ npm install --save broccoli-resin

Usage

var resin = require('broccoli-resin');
// Feel free to pull in other rework plugins
var rework = require('rework')
 
tree = resin(tree, {
  // Tell it what browsers to prefix for
  browsers: ['last 1 version', 'ios', 'android 4'],
 
  // Add a namespace to your classes to avoid collisions
  namespace: 'myapp',
 
  // Add a license to the final output
  license: '// Copyright 2013 and stuff \n',
 
  // Generate sourecemaps for debugging
  debug: true,
 
  use: [rework.prefixSelectors('#myapp')]
});

API

resin(tree, opts)

Initialize a new resin with the given string of regular CSS. Optionally supply an object with options as the last argument.

Options

browsers

Type: Array Default: []

This is a list defined at ai/autoprefixer#browsers.

namespace

Type: String Default: ''

This namespace prefixes your classes on output so you can avoid collisions.

license

Type: String Default: ''

This is just a string that gets concatenated at the top of your file.

debug

Type: Boolean Default: False

This enables sourcemap support.

use

Type: Array Default: []

An array of rework plugins that you'd also like to run.

License

MIT © Alex Sexton

Thanks

Heavily cargo-culted from kevva/broccoli-rework

Package Sidebar

Install

npm i broccoli-resin

Weekly Downloads

1

Version

0.1.0

License

MIT

Last publish

Collaborators

  • slexaxton