Hi,
I am learning gsap, I found this example on codepen
Now I would like to use gsap.timeline or gsap TimelineMax, I change it like this
var text = $(".split");
var split = new SplitText(text);
var tl = new TimelineMax(); // added timelinemax here
function random(min, max){
return (Math.random() * (max - min)) + min;
}
$(split.chars).each(function(i){
tl.from($(this), 2.5, { // and used it here
opacity: 0,
x: random(-500, 500),
y: random(-500, 50