Skip to content

Instantly share code, notes, and snippets.

@larzconwell
Created May 31, 2012 00:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save larzconwell/2839732 to your computer and use it in GitHub Desktop.
Save larzconwell/2839732 to your computer and use it in GitHub Desktop.
Main = ->
this.index = (req, res, params) ->
this.respond params,
format: 'html'
template: 'app/views/main/index'
exports.Main = Main
###
# Compiled JS output
var Main = function() {
return this.index = function(req, res, params) {
return this.respond(params, {
format: 'html',
template: 'app/views/main/index'
});
};
};
exports.Main = Main;
###
###
# Working JS alternative
var Main = function () {
this.index = function (req, resp, params) {
this.respond(params, {
format: 'html'
, template: 'app/views/main/index'
});
};
};
exports.Main = Main;
###
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment