connect-assets-jade
Expose your jade views in the browser using connect-assets
.
![build status](https://secure.travis-ci.org/TroyGoode/connect-assets-jade.png)
Tips are welcome, but not expected.
Installation (via npm)
$ npm install connect-assets-jade
Usage
See example app in /example
directory.
Integration with connect-assets
is done like so:
var express = require('express')
, assets = require('connect-assets')
, jadeAssets = require('connect-assets-jade')
, PORT = 3000;
var app = express.createServer();
app.configure(function(){
app.set('views', __dirname + '/views');
app.set('view engine', 'jade');
app.set('view options', {layout: false});
app.use(assets({
jsCompilers: {
jade: jadeAssets()
}
}));
app.use(app.router);
});
app.get('/', function(req, res){
res.render('home');
});
app.listen(PORT, function(){
console.log('Example app for connect-assets-jade running on port %d.', PORT);
});
Credits
License
MIT License
Author
Troy Goode (troygoode@gmail.com)