Aptana 3 jquery code assist/hinting
I've been using aptana forabout a week now, and just picked up jquery for the last couple of days. But I'm mort getting any code assistance, which will help me with syntax add stuff as i learn. I've ben searching fit a few days already and I'm not getting a straight answer how to enable this. I read it's supported and should have assistance by creating a new html and javascript template and it should do it...unfortunately it doesn't.
开发者_JAVA技巧I can use some help to shred some light on this please.
I apologize for any typos, I'll typing this from my phone.
to have code assist with aptana 3 follow this instructions https://wiki.appcelerator.org/display/tis/JavaScript+Library+Support i.e. Go to
Commands -> Bundle development -> Install Bundle and then select jQuery from the resulting dialog box.
You can then write jQuery code and get assistance.
Please go to the official documentation page and follow the instructions step by step (it is a piece of cake): http://wiki.appcelerator.org/display/tis/Using+JavaScript+Libraries#UsingJavaScriptLibraries-Viewingcodeassist%28usingjQueryasanexample%29
Selecting "Commands | Bundle Development | Install Bundle" didn't show any option to enable jQuery in the resulting dialogue box.
Here is how I fixed the problem:
I went to https://github.com/aptana/javascript-jquery.ruble/releases and downloaded the most recent release ending in .studio3 (ignoring the ones that ended in .titanium, of course since I'm using Aptana Studio and not Appcelerator's Titanium). Just below the name of the release are several options to get the file in different formats -- I chose the .zip format.
I unzipped the file I downloaded and copied the extracted folder ("javascript-jquery.ruble-3.4.2.201308081805-studio3" in my case) into the "~/Documents/Aptana Rubles" folder. (on a Windows Vista or 7 or 8 or 8.1 machine, I'd imagine it'd be in "X:\Users\UserName\Documents\Aptana Rubles" where X is the drive on which you store your user-profile stuff, and "UserName" is the name you use to login to the computer. On a Windows XP machine it'd probably be "C:\Documents and Settings\UserName\Documents\Aptana Rubles")
After copying the folder to that location, I clicked on "Commands | Bundle Development | Update User Bundles". Gave it a minute to process that, then I clicked on "Commands | Bundle Development | Install Bundle" and the jQuery option appeared at the bottom of the list. I clicked on it, and it installed the bundle properly.
All of the projects in my Aptana workspace were closed when I installed this bundle, so I opened one up and opened its index.html file to test this new bundle. Inside a pair of <script> tags, I typed $. and immediately got code-hints. So it appears to work.
Hope this helps.
If the above Answer from user1387219 (https://stackoverflow.com/a/10535593/1256697) show no code-assistance for your still startedd Project, try the following (after done the "jQuery Bundle Stuff" user1387219 described:
- Click Project >> Properties
- Go to "Project Build Path"
- Activate the Checkbox in front of the jQuery-Library you need.
- Save with ok.
Now you should have working code-assistance. Try to type $ and press CTRL+Space.
精彩评论