I'm animating an svg file, and in order not to bloat my code I have written the follow function:
function animateSingleAtt(svgName, element, attToAnimate, attValue, animationTiming) {
svgName.select( element ).animate({
attToAnimate : attValue
}, animationTiming);
}
All parameters are loaded just fine, except for attToAnimate. I have no clue as to why this is – it is just passed to the svg element as an attribute named 'attToAnimate'.
I have tried logging it outside of the animate-function, and when I do that, it's passed just fine.
Any help will be greatly appreciated!