Search code examples
ide

Get the API reference of a library without leaving the IDE?


I wonder if there's a way to get a list of classes, constants and functions in a library without going through the code of that library? I don't mean something like intellisense, because it doesn't give you an overall view of the library, it just tells you how you can proceed from the first things you've typed in. I mean something like this.

I always import a library and then search for a summary of its API in its documentation page, but since I'm not a pro, I'm afraid I've been taking the dumb way the whole time. So I suspect there should/might be a faster way for getting this summary without leaving the IDE?

(Although I'm using VSCode as my IDE [and I'd be happy too if your answer is based on VSCode], this question might have a more generic solution which I'm unaware of, and thus not tagging it merely as a VSCode specific question.)


Solution

  • I have found a VSCode-specific answer to this question here. First ctrl+click (or F12: Go to Definition) on the imported library to open its code. Then:

    You can navigate symbols inside a file with **Ctrl+Shift+O. By typing : the symbols will be grouped by category. Press Up or Down and navigate to the place you want.