Hello,
I've finally succeeded to migrate Blake Bowen Modifiers path 1 exemple to getProperty.
It was a problem of scope....
Thanks Jack for your help. It was great help. Here is the code of this exemple of migration from _gsTransform to getProperty to newbies :
var ball = document.querySelector("#ball");
gsap.set(ball, { x: 100, y: 100 });
var getter = gsap.getProperty(ball);
gsap.to(ball, {
duration: 3,
x: 800,
y: 300,
repeat: -1,
yoyo: true,
modifiers: {
y: function(y) {
var gx = getter("x");
console.log(gx);
return (parseFloat(y) + Math.cos(gx / 100) * 30) + "px";
}
}
});