It's posible to wrap multiple tweens as an effect, no just one?
For example:
gsap.registerEffect({
name: 'decodeWord',
effect: (targets, config) => {
gsap.set(targets, {
color: 'white',
textShadow: `0 0 0`
});
gsap.to(targets, {
duration: 1,
opacity: 1,
scrambleText: {
text: config.newText,
chars:'lowerCase',
revealDelay: 1,
tweenLength:false
},
})
return gsap
},
defaults: {}, //defaults get applied to any "config" object passed to the effect
extendTimeline: true, //now you can call the effect directly on any GSAP timeline to have the result immediately inserted in the position you define (default is sequenced at the end)
})