haxe - an open source programming language for the web
A developer friend of mine recently turned me on to haXe (pronounced “HAX-ee”, a sort of generic programming language that gets compiled into java, php, active script (flash), javascript, etc. This means you write all your code in one language (haXe) and then compile it to whatever application language you want. If it spits out javascript, for example, it delints it (no white spaces or comments) and renames all the name spaces to short (abstract) variable names to create the smallest file possible. Because you’re authoring everything in haXe, the compiler runs like any other compiler, helping to ensure your code will execute. I’m not sure how it works if you want to use 3rd party libraries (I’m thinking about things like Scriptaculous), but it sounds very, very promising. I’d love to see some more qualified folks than myself evaluate it.
The Web is evolving quickly, with different technologies needed at different places. For instance, if you want to create a website now you’ll have to handle several languages :
on the server side : a web language such as PHP, Perl, Ruby or Python. on the client side : Flash (ActionScript 1, 2 and now 3) and Javascript / DHTML / AJAX.The haXe programming language is uniting theses different platforms under one language. It brings features that are making it easy to deal with a dynamic world such as DHTML or Databases, while still bringing you a full-featured type system with a compiler that will detect errors early in the development phase.
Basicly, what haXe can do is :
create Flash SWF files using Flash APIs for Players 6,7,8 and soon 8.5 generate Javascript code using Browser DHTML API, so you can create AJAX web applications generate Bytecode that can be used on the Server side (using an Apache plugin) or packed into standalone executableEach of theses platforms have their own API, but they share the same programming language and the same standard library, so if your classes are pure code (using no platform-specific API) then they can be compiled and used everywhere, depending on your needs.
Also, haXe make it easy to interoperate between theses different platforms, by providing common protocol libraries. Please note that it’s still possible to use haXe on only one platform if you want for example keep your current working code.
