Search code examples
javascripteclipseintellij-ideaidewebstorm

Javascript Intellisense in IDE


How does Intellisense work in IDEs for JavaScript such as Webstorm or Eclipse?

Where do the suggestions come from?

Can we write the code to make the suggestions more accurate?

Sample image


Solution

  • Please see http://blog.jetbrains.com/webstorm/2014/07/how-webstorm-works-completion-for-javascript-libraries/ for some hints on improving JavaScript code completion in WebStorm. In general: suggestions are taken from index that is built for all .js and d.ts files available in the project/set up as libraries. To make the completion better, you can try using JSDoc annotations/typescript definition stubs