Skip to content

SlexAxton/broccoli-resin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

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

About

Broccoli flavored resin

Resources

License

Stars

Watchers

Forks

Packages

No packages published