I am a novice at writing Javascript and I know my coding is terrible. I have been creating a few examples of moving elements around the screen as part of my learning. I just discovered GSAP and marvel at the capability. i have stopped my writing and am now spending time learning how GSAP works -- a long way to go before I create some of those fancy animations.
Anyway, there is one feature jwt_move that I coded and seems to be missing from GSAP.
In the x and y options for the basic moves, in addition to number of px, I also coded in"left" "right" "center" "top" "bottom" "middle" which would move the element to the edge of the viewport. In addiion, I coded a bounds/nobounds option and if 'edge' is selected for this option, a move of say 10000px would stop at the edge of the viewport.
In addition, I could move an element to the viewport edge and then offset from that edge by a number of px using 'offsetX. The web site has my example. There is some simple documentation for the options at:- http://www.trfc.me/jwt_scripts/documentation/jwt_move_description.shtml
The example:
http://www.trfc.me/jwt_scripts/examples/jwt_move_example.shtml
I have not found a way of doing these functions with GSAP.
Please don't criticise my coding -- I know it is terrible -- but what it does is a feature I could not find in GSAP.
Note: if the viewport size is known, maybe scale could also be limited to the viewport edge as an option.