component-stylus

Transpiles stylus for component

npm install component-stylus
8 downloads in the last week
54 downloads in the last month

component-stylus

Build Status

Seemlessly use stylus in your components.

Usage


// component.json
{
  ...
  "styles": [
    "base.styl",
    "nav.styl"
  ]
  ...
}

// builder.js
var fs = require('fs')
  , Builder = require('component-builder')
  , c7tStylus = require('component-stylus');

var builder = new Builder(__dirname);

builder.use(c7tStylus);

builder.build(function(err, res){
  if (err) throw err;

  fs.writeFileSync('public/package.js', res.require + res.js);
  fs.writeFileSync('public/package.css', res.css);
});
npm loves you