Vexi PlatformVexi Platform
vexi: easy, extensible, flexible

Saturday, August 29, 2009

Vexiscript Destructuring & Iterating Values

I have made a couple of improvements to vexi script (our dialect of javascript).

1) Destructurings

Destructurings in Vexscript are the same as those introduced in Mozilla Javascript 1.7.

//Useful for swapping values
var a = 1;
var b = 2;
[a,b] = [b,a];

// Or for handling multiple returns
var a,b,c;
[a,b,c] = f();


2)Improved for-in loop

Its pretty straightforward

var o = {a:3,b:2,c:1};
for(var k,v in o){
    // ...
}

// one might use this convention for an array
var arr = ["a","b","c"];
for(var i,v in o){
    // ...
}

This is not the same as any of the methods (there are at least 2) you can use in mozilla javascript. They support the form for(var [k,v] in o), which is unfortunate at is makes it an ambiguous syntax. It could be seen as a destructuring of just the key (so its not usually possible to have an array as a key in javascript, but its still not a very good choice in my opinion).

The other method is for each(var v in o), here the each key word just changes the behaviour of the loop. This is not really ideal as it is not useful if you need both the key and the value (which is the case perhaps as often as not).

Friday, August 14, 2009

Vexi Docs Preview

Courteousy of Mike and his inginuity:
http://vexi.sourceforge.net/docs/3.0/

It is in need of improvement and organisation but it's starting to look good and proving useful already to those of us who need it.

Wednesday, July 01, 2009

Vexi 3.0 build 3539 and VexiDev 0.3.5 Released

I uploaded a new build of Vexi, revision 3539 which has a slew of minor improvements and bugfixes.

Release announcements: Sourceforge, Freshmeat

Mike also updated VexiDev 0.3.5 last week after we discussed there were some issues with the update site for 0.3.4 preventing it installing.

Release announcements: Sourceforge

Monday, June 29, 2009

Vexillology

Vexillology is the scholarly study of flags... and nothing to do with the vexi platform. I hope that clears things up!

Monday, May 18, 2009

Vexi Website Updates

A long overdue update is in now occurring.

The Vexi forum and blog are now mostly done. The wiki will take a bit longer (moving from Mediawiki 1.6 to 1.14).

A more unified web presence and a better homepage should help Vexi retain the visitors to the website that don't seem to stick around at the moment.

Get The Vexi Platform at SourceForge.net. Fast, secure and Free Open Source software downloads Sponsored by WEBenableIT Java Network Member