I have seen $.fx.step. backgroundPosition = function(fx) {...}
in some javascript snippet. I can't find much infomation about $.fx
.
Can anyone provide a link to some detailed tutorial on $.fx
?
PS: I have read this: .html
But as a javascript newbie, I didn't quite get the point of it.
I have seen $.fx.step. backgroundPosition = function(fx) {...}
in some javascript snippet. I can't find much infomation about $.fx
.
Can anyone provide a link to some detailed tutorial on $.fx
?
PS: I have read this: http://onwebdev.blogspot./2011/02/jquery-fx-object.html
But as a javascript newbie, I didn't quite get the point of it.
Share Improve this question asked May 12, 2013 at 11:22 CDTCDT 10.7k21 gold badges73 silver badges99 bronze badges 1-
In your second snippet,
fx
is just a parameter to the function, it's not anything special. – Barmar Commented May 12, 2013 at 11:25
3 Answers
Reset to default 6In short: fx
is the basis of all jQuery effects like .animate
, .hide
, etc.
Code like the one you posted is meant to extend jQuery.fx
.
You can see more details about $.fx HERE
A new jQuery plugin that supports animating CSS colors of elements by using the new jQuery.fx.step.
Here is stated, that fx
object is declared as follows:
fx: function( elem, options, prop ) {
this.options = options;
this.elem = elem;
this.prop = prop;
if ( !options.orig ) {
options.orig = {};
}
}
read more that link.