Jump to content


Ctags for GSAP

Moderator Tag

Warning: Please note

This thread was started before GSAP 3 was released. Some information, especially the syntax, may be out of date for GSAP 3. Please see the GSAP 3 migration guide and release notes for more information about how to update the code to GSAP 3's syntax. 

Recommended Posts

Hi all.


I have created a ctags file for TweenMax and wondered if there was any interest from other users before I extended this to other classes (TimelineLite/Max and various plugins).


I used a modified source to create the file (ctags doesn't like the way that TweenMax is defined in the original source) and have yet to rigorously test the result, but it seems to be working for me.


I have attached the file along with a tags file for Geany. I am apparently not allowed to upload this type of file :( If someone can suggest a reason/workaround I'd be very grateful. If anyone would like to use it or test and give feedback that would be great :)


Note that currently the path to TweenMax.js is specified as though it is in the same directory as TweenMax.tags

Link to comment
Share on other sites

Hello Spymastermatt, and Welcome to the GreenSock forum!


I am not familar with ctags, maybe someone can offer a solution.

In the mean while, do you have an example so we can see your code example and in context? Without seeing an example this will be really hard to debug and test.

Here is a video tut on how to create a codepen example.

This way we can test your code live on codepen to better help you!

Thanks! :)
  • Like 1
Link to comment
Share on other sites

Hi and welcome to the GreenSock forums,


Thanks for the suggestions. This is the first request we have seen for ctags, in fact I had to google what they were  8-)


It's my limited understanding that the benefit of ctags is mainly that navigating the source may be easier in some editors for people that would be dealing directly with writing the GSAP source code.


Would you mind giving us a little info pertaining to what the benefit to our users would be? 


FWIW we are very careful about adding filesize to the source code unless it adds a "must-have" feature or helps performance. We also have many exciting new features under active development. We just need to understand all the implications and demand from our users before choosing a particular path.


Thanks again for the suggestion.


Happy Tweening


* to attach a file to a forums post you need to zip it first. Or you can host it on your own web server and send a link.

  • Like 1
Link to comment
Share on other sites

@Jonathan Sorry I perhaps didn't explain very well. It's not a problem I'm experiencing, it's a project I am undertaking which has gone far enough for my own usage but which I could extend if it would benefit other users.


@Carl Your right that the main purpose of ctags appears to be to find the definition of a property/function in the source but the reason I created the file is that Geany (which uses a similar but slightly different format) can use tags files to provide code hints (super useful for me getting to grips with Tween Max :) ).

AFAIK both sublime text and notepad++ can also use crags, though I'm unsure whether they use it to provide code hints.

It was never my intention that the files be added to the source but that they be available as a separate resource for anyone who wants them.


I will upload the files here in case anyone wants them when I am back at my computer.

Link to comment
Share on other sites

Ah, ok. Thanks for the explanation. Yeah, as long as they are separate files that anyone can grab that sounds like a nice contribution. Feel free to upload them here with instructions on how to use so that people that are interested can give them a whirl. Thanks.

  • Like 1
Link to comment
Share on other sites

Thanks for sharing Spymastermatt :)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.