How to show JQuery Documentation in a web project.

Hello,

this one really drives me crazy. I do not get it done, that jquery documentation shows up in a web project. i never manged it in IntelliJ 11 and after updating to 12 its the same. I think its the third time i tried this, so i am  quite frustrated now.

I set up a simple webproject, included JQuery in Library and included a reference in the code. I went to preferencies > Javascript > Libraries downloaded the documentation and had a look at the scope.

fine..

I write something like  $("#test").html(); in my code, set the cursor to html() and click shit F1. Nothing happens ever. Menu item is grey, and never clickable.

Quick Definition look up works fine leading to the jquery source.

What am I doing wrong?

Sincerly Ingo

5 comments

Hi Ingo,

Shift+F1 opens external documentation (browser) but as far as I understand you want to see the documentation inside the ide itself. Please try to press Ctrl+Q on target element instead.

Denis

0

Ok, i figured out the following:

a) Quick Documentation ( CTRL + J on Mac ) for jQuery is not working within a script tag in a HTML Page ( => No documentation found in source code. )

Its only working within an external js - file, thats fine.

b) I stil wonder why i don't get anything when i like to see the external documentation. Short cut is not working and the menu item is disabled - what do i have to do to get this run.

See my configuration in the screenshots.



Attachment(s):
Bildschirmfoto 2013-04-19 um 17.47.16.JPG
Bildschirmfoto 2013-04-19 um 17.34.33.JPG
0

Further problems:

I included underscore.js and backbone.js in the Library and added the links to the documentations.

Menu Item "External Documentaion ( Shift F1 ) not available as before.

Sometimes i get code hints for underscore ( Quick Documentation ), sometimes not, on the same method call.For Backbone i only get nothing.

Clicking the up - arrow leads to the online documentation ( fine ) and works both for underscore and backbone.

I use JSLint and i am not able to get Lint tolerate the _.()  call of underscore, allthough i added the "_" to the predefined vars as i did with $ and Backbone where it works as suspected.

EDIT : This one i got now, there is an extra checkbox for that.


I must say, that i hoped that Javasript - Support would be much better in "the smartest Javascript IDE", assuming that webstorm works identically to IntelliJ.

Well, i hope that i am doing something basically wrong, i will try the same thing on PC next days and hope it will work better than on Mac.

0

If you are using Intellij IDEA, Settings->JavaScript->Libraries leads you to "Download" button which allows to dowonload a library locally and automatically sets an external documentation link but it does not download any documentation. Anyway, if you click "Download", choose "jQuery" and click "Download and Install", jQuery will be set up automatically and Shift+F1 will start working including the case you have mentioned (it actually opens http://api.jquery.com/html). For whatever issues you get I'd recomment to write a bug report in YouTrack.

0

Following the documentation on

http://www.jetbrains.com/webstorm/webhelp/documentation-look-up-in-external-javascript-libraries.html

or the blog on

http://blog.jetbrains.com/webide/2011/01/external-api-docs-support-for-popular-javascript-frameworks/

There is claimed:

To view documentation on a symbol defined in an external JavaScript library                                      

  • Position the cursor at the symbol in question and choose                     View | External Documentation, or press                     Shift+F1.                      



See the screenshot to see what realy goes on:

Putting the cursor at the symbol ( in the source code ) does nothing. Menu item is disabled. Opening the quick definition says thats there is no documentation.

It only works if i open the auto-complete dialog and navigate to the method of interest. Then it works fine as suspected and opens jquery documentation....

I don't know if this is an mac-only issue, but it tooks me hours to get it, so much lost time....

please update your documentation or explain better  how to do it....


thanks....



Attachment(s):
externalDoc.png
0

Please sign in to leave a comment.