My dear mates, lads, dudes and off course boys and girls, today is the day! The next major version of RightJS with version 1.5.0 is finally out! There were quite a lot of changes, some of them are great, some fascinating and some just cute.
The reason is simple. It allowed to reduce the size of the builds from 47k and 35k to 41.5k and 30.7k for minified and packed versions respectively. It also left space for new features and optimizations.
For you, as a developer, it doesn't changes practically anything. All the difference is that you'll need to drop another file along with the core file and that's pretty much it. RightJS will automatically load it up when it needed.
And naturally you can have the old style all-in-one builds by embedding the olds patch at the custom builds page
Check the download page for more details.
Check the benchmarks page.
Now you can process all the borders separately, you also can run visual effects on the backgroundPosition properties, you even can feed several options in one, like that
$(
'element').morph({
padding: '10px 10px',
marging: '1px 2px 3px 4px'
});
$(
'element').scroll({
x: 100, y: 20
});
var mixin = {
selfIncluded: function(klass) {
klass.prototype.mambo = 'jumbo';
}
};
var Klass = new Class({
include: Mixin
});
it supports both selfIncluded and selfExtened methods. Underscored versions self_included and self_extended are also work.
Happy metaprogramming!
var func = function() { return $A(arguments).join('-');
func.rcurry('bany', 'many')('any'); // -> 'any-bany-many'
Chains work simple
var list = [];
var f1 = function() { list.push(1); };
var f2 = function() { list.push(2); };
var f3 = function() { list.push(3); };
f1.chain(f2).chain(f3)(); // -> list == [1,2,3]
var Klass = new Class({
include: Options,
initialize: function() {
var args = this.cutOptions(arguments);
}
});
This will chop off an options hash from the nd of arguments, feed the setOptions method and return the left arguments as an array.
This is about it. Have fun!