andybeeching / juice forked from ashb/juice

Server-side Javascript framework built on top of JSGI

This URL has Read+Write access

juice /
name age message
file .gitignore Sun Oct 25 12:39:37 -0700 2009 Removed and ignored bin/juice (auto-generated) [Dominic Baggott]
file CONTRIBUTORS Tue Oct 27 14:47:24 -0700 2009 Adding Sarah Clark to contributors (she made th... [Dominic Baggott]
file LICENSE Thu Oct 01 12:03:42 -0700 2009 Add license [Ash Berlin]
file README.markdown Loading commit data...
directory bin/ Tue Oct 27 13:00:07 -0700 2009 Record directory [Ash Berlin]
file install.js Sat Oct 24 14:04:35 -0700 2009 [#3] Create an installer that will install modules [Ash Berlin]
directory lib/
directory packages/
directory skeleton/ Mon Oct 26 16:58:58 -0700 2009 tidy up installer - mainly around batch file tm... [Ash Berlin]
directory t/ Wed Oct 14 16:02:02 -0700 2009 Small tweaks to get check CGI still works as it... [Ash Berlin]
directory tests/ Mon Oct 26 14:43:26 -0700 2009 Validation routines throw on error now. Renamed... [Dominic Baggott]
README.markdown

Juice? JavaScript? WTH?

A server-side Javascript webframework built on top of the JSGI protocol. Well, the version 3 proposal using the built in asynchronous Zest HTTP server.

If you like JS as a language, and clearly I do, then hopefully you'll get on with Juice:

var juice = require('juice');
var app = new juice.Application;

app.controllers.index = function() {
  return {
    status: 200,
    headers: {},
    body: ["Hello Juicers!"]
  }
}
app.actions = { "/?" : { action: "index", raw: true } };
exports.app = app.setup();

There's more to it than this obviously -- a getting started guide will be available with version 0.1 which is due for release on 20th Oct. 2009. Edit: The code is mostly ready -- we're just holding off to test things a bit better and to finalize the design of the website.

Juice is currently known to run on Flusspferd, and should run on other CommonJS platforms in the future -- it just hasn't been tested yet.

As for running your Juice app - well it ships with its own development server (which performs surprisingly well) and a CGI version for easy deployment. Version 0.2 will have FastCGI support.