I've been curious about LunaScript since its announcement (http://www.asana.com/luna), and I thought I'd survey here what existing tools are similar to it - in particular, maintained and usable software. From the blog post:
A Lunascript application specifes a data model and a function from the model to the view or user interface, annotated with handler functions from user inputs to model mutations. From this the Lunascript compiler produces a functioning Web 2.0 application -- the client-side JavaScript, the server-side SQL, and everything in between -- complete with real-time bidirectional data synchronization. There's no need to write separate code to help the server figure out which values need to be sent to the client: the server can do this by simulating the UI. Because a Lunascript application only specifies how the UI should look given the current data (rather than how the UI should be updated as changes happen) it's impossible to write a UI that loads correctly but does not stay correct as changes are made.
The main feature of interest is the reactive programming/incremental evaluation/bidirectional databinding/whatever you want to call it. That the bindings straddle the browser, app server, and RDBMS is deeply intertwined with the ability to generate code to run on each of these platforms from a single program.
To get started, here are some similar work I'm aware of:
- Ur/Web: this is probably the closest related work , but appealing primarily to a FP audience, with syntax/approaches that may feel very foreign to JS hackers.
- Swift: splits a single program into client/server code from a single program using IFC techniques; resembles GWT; research; dead.
- OpenLaszlo: a reactive client-side UI platform with a similar XML/JS blend of syntax catering to web developers; mature, usable open-source platform with commercial support. See also Flex.
- JavaFX is similar to OpenLaszlo but for Swing/Java.
- Macroprogramming/Amorphous Computing: very much still relegated to research. These are the only example of research I'll mention since that rabbit hole runs deep; again, I'm more interested in maintained and usable software.
Anything else out there that may be of interest?