A week ago I tried to do small animations in angular 2 app by GSAP library. The goal here is, gsap works with typescript compiler and we can use it as types in our angular app. The steps are easy and I summarize them into few ones:
- Do an “npm install –save @types/gsap”
- Include the gsap in the component or service “var gsap = require(‘gsap’)”
- Use it “var tl = new gsap.TimelineLite()”
If you are looking for TimelineMax class functionalities, you may need to convert them to types first and add it to your angular 2 app.