SpringbokJS

Springbok Framework for NodeJS

Documentation

This project is maintained by Christophe Hurpeau

SpringbokJS

SpringbokJS is an experimental framework for NodeJS and can be used for Single-Page Applications

Hello World

The Hello Sample is available here.

main/controllers/Site.js

The controller receive a request and render a result

App.Controller({
	Index:App.Controller.Action(function(req,res){
		var v=req.validator(), name=v.str('name',1).notEmpty().val;
		res.end(this.H.t('Hello %s!',[ v.isValid() ? name : 'World' ]));
	}),
});

config/routes.yml

This configuration file tell the Router where a request should go

main:
	"/": ["Site.Index"]