jasonmorganson
9/24/2011 - 3:56 PM

Serve CoffeeScript, Jade, Stylus with Zappa.js and connect-assets.

Serve CoffeeScript, Jade, Stylus with Zappa.js and connect-assets.

zappa = require 'zappa'

zappa ->


	@configure =>

		@set 'view engine': 'jade'

		@use require('connect-assets')()
		@use 'bodyParser', 'methodOverride', 'static'


	@configure

		development: -> 
			@use errorHandler: { dumpExceptions: on, showStack: on }

		production: -> 
			@use 'errorHandler', 'staticCache'


	### Routes ###

	@get '/': ->
		@render 'index'