8

There is no intellisence in visual studio code. i have installed and tried many extensions but it does not helping me out. It only shows those functions and variables that are already used in my code file. Here is the list on extension i have installed and the screenshot.screenshot of vs code intellisence and extension that i have installed

Gama11
  • 31,714
  • 9
  • 78
  • 100
Usama Khan
  • 259
  • 4
  • 10
  • VS code only gives intellisense when the function or class you are using has proper documentation. Like `express` npm. – Shaharyar Mar 04 '19 at 19:07
  • I have used express before this but its same. Only those functions and variables are in intellisense after “.” that are already in the code file, then I decided to reinstall vs code and extensions and start new project. – Usama Khan Mar 04 '19 at 19:13
  • VS Code fetches type-definitons for node and you should be getting intellisense there without any of those extensions. Check your VS Code settings under JavaScript and see if anything is disabled that is related to Suggestions and Intellisense. – cinnaroll45 Mar 04 '19 at 20:45
  • Also, node should be in your path for JavaScript Language Service to get those definitions. Further reading: https://code.visualstudio.com/docs/nodejs/working-with-javascript – cinnaroll45 Mar 04 '19 at 20:51
  • 1
    There is no problem with the vs code i just solve this by npm install —save @types/node – Usama Khan Mar 04 '19 at 21:11

2 Answers2

13

There is no problem with the vs code i just solve this by

npm install --save @types/node

This is one of development dependencies and —save is just an argument that reflect the info related to this in your package.json file

Usama Khan
  • 259
  • 4
  • 10
1

Use this command in Mac :

sudo npm install -g --save @types/node --unsafe-perm=true --allow-root
whoami - fakeFaceTrueSoul
  • 17,086
  • 6
  • 32
  • 46