Looks like a function declaration:
function(i) {
So i is the value passed to the function (which is declared built-in as an anonymous function) as its first parameter, presumably by the internal operations of the retarder method through which you pass the function to.
Rewriting the code to make it more readable makes it easier to understand:
ul.css( { width: 10, overflow: 'visible' } ).retarder(100, function(i) { i.css('visibility', 'visible').animate( { width: ul[0].wid, left:-50 }, { duration: 500, complete: function() { ul.css('overflow', 'visible'); } } ); } );
And you can rewrite it even more clearly:
ul.css( { width: 10, overflow: 'visible' } ).retarder(100, functionToPassToRedtarder); function functionToPassToRetarder(i) { i.css('visibility', 'visible').animate( { width: ul[0].wid, left:-50 }, { duration: 500, complete: functionToPassToComplete } ); } function functionToPassToComplete() { ul.css('overflow', 'visible'); }
Rob
source share