Cannot download Javascript library from Settings to support intellisense

Hi, everyone, i see a lot "unresolved function or method" in even the most popular nodejs library such as express. I know i need to download the library to support intellisense. But I have struggled to find a way to download javascript from settings page to support my javascript code intellisense,  for some reason i cannot see that full list of community stubs, only see 3 not relevant. Attached is what I see. I searched online and cannot see anyone has this issue.  Please see my attached screen shots

 

Please help! thanks in advance.

 

DK



 

 

14 comments
Comment actions Permalink

the DefinitelyTyped repository structure has changed - no more packages are available at https://github.com/DefinitelyTyped/DefinitelyTyped, they have been moved to https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types.

Logged as https://youtrack.jetbrains.com/issue/WEB-26160, please follow it for updates

0
Comment actions Permalink

Thanks for the information.

0
Comment actions Permalink

Note that you can still download preferred stubs manually from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types and then set them up as a library: in Preferences | Languages & Frameworks | JavaScript | Libraries, press Add..., then +, Attach files, select the files you have downloaded

1
Comment actions Permalink

Hi, is there a way to change the repo in intellij settings or config files?

0
Comment actions Permalink

No, it's hardcoded:(

0
Comment actions Permalink

hi, Elena:

 

I have tried downloading stub and refer to .ts files, but it didn't work (see attached). The basic function "get" of express library still not recognized. Can you please advise when Webstorm will have a new release that make a permanent fix, or even a patch will be helpful. One of the main reasons I bought web storm is the intelligence feature. Please help
 

 

please advise. 

Thanks

DENNISKANG

0
Comment actions Permalink

Current version of Express stubs (@types/express/index.d.ts) doesn't export Express module, it exports 'e' instead. So, the IDE can't match typescript definitions with the js code:(

0
Comment actions Permalink

did you try? this is also not working

0
Comment actions Permalink

Hi, Elena: I must have done something wrong - it still refused to resolve the "get". Please see my steps below and correct me where I configured wrong. 

first, i download the ts file and save to my project "vendorLib/..." folder, I corrected the reference path of node.d.ts. Then add reference to library. The project runs fine, but this function was not resolved. 

 



 



 



 

 

 

0
Comment actions Permalink

It might be using a different library - the one from @types, for example...

 

Try Ctrl+clicking on `use()` , for example - what declaration are you taken to?

0
Comment actions Permalink

hi, Elena:

 

I researched online and found an ugly workaround using "new require".... Anyway, can you advise when JB/Webstorm will have a permanent update/fix for this issue after the TypeScript update?

 

Thanks

 

0

Please sign in to leave a comment.