LESS CSS middleware.
lessmagic is here to make using LESS CSS LESS of a pain. (pardon the pun) It is a Connect/Union middleware and Flatiron plugin that serves autogenerated .css files from your .less files.
Why, npm of course!
npm install lessmagic
Well, you just use it as middleware!
var http = require'http';var express = require'express';var lessmagic = require'lessmagic';var app = express;appuselessmagic__dirname + '/markup';appuseexpressstatic__dirname + '/public';httpcreateServerapplisten3000;
Or with Flatiron, as a Broadway plugin:
var flatiron = require'flatiron';var lessmagic = require'lessmagic';var app = flatironapp;appuseflatironpluginshttp;appuselessmagic __dirname + '/markup';appuseflatironpluginsstatic __dirname + '/public';appstart3000;
There's also a bunch of examples for other frameworks.
Returns the lessmagic middleware.
opts will be passed along to the less.Parser.
path is given, it is prepended to
Awesome, open an issue! If you're really awesome, send me a pull request!
Check out the docco docs at http://nathan7.github.com/node-lessmagic/ or read the source!