Snap.svg
HTML
<script src="//cdn.jsdelivr.net/snap.svg/0.1.0/snap.svg-min.js"></script>
<script src="http://cdnjs.cloudflare.com/ajax/libs/gsap/1.14.2/TweenMax.min.js"></script>
<h2>Hello this is a GSAP TimelineLite Animation</h2>
JavaScript
s = Snap(400, 620);
var path = s.path("M0 0 L0 501 L200 80");
function pathMorph() {
path.animate({ d: "M0 0 L501 0 L501 501 L0 501" }, 1000, mina.bounce);
}
//GreenSock animation code
var tl = new TimelineLite();
tl.from("h2", 1, {x:400, opacity:0, delay:1})
.call(pathMorph) // place pathMorph in middle of animation sequence;
.to("h2", 1, {x:200, opacity:0}, "+=1"); //fade out text one second after pathMorph called