maja

The maja compiler translates Vala code into Javascript code.
The generated code is straight usable in a web browser or in other environments.
Currently supported profile is dova (partial dova-base and dova-model), a new runtime type system for the Vala language much close to the Javascript model. GLib profile and others could be supported as well.

Latest version is 0.1. Grab the sources: maja-0.1.0.tar.gz.
Development version at the git repository.
Report bugs and feature requests at the issue tracker.

why maja

examples

Most of the maja code can be found in the source under tests and examples. The qooxdoo demo browser is being ported in the qxdemo branch, showing you can do pretty much everything with Maja.

build

Requirements: valac and libvala-dev

Type make to build maja.
Installation is not currently well supported, thus discouraged.

usage

The majac binary has similar options to valac. Main usage is to translate Vala code into Javascript code.

majac/majac -o output --vapidir dova-vapi --vapidir vapi file1.vala file2.vala

This will create a single output.js file. In order to use it you must first load maja-utils.js and dova-base-0.1.js then your output.js.

status

Majac is not yet complete from a features view point (like async methods) but it is possible to do everything you could do with Javascript. The dova system is still young and incomplete, not letting majac to completely map all Javascript functions into Dova functions.